Skip to content

Commit 04f8b85

Browse files
committed
Better document the definition of an invalid date
Part of #250
1 parent 99d62c7 commit 04f8b85

File tree

2 files changed

+14
-4
lines changed

2 files changed

+14
-4
lines changed

R/invalid.R

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,13 @@
22
#'
33
#' @description
44
#' This family of functions is for working with _invalid_ calendar dates.
5-
#' These represent dates that don't exist, such as
6-
#' `year_month_day(2019, 02, 31)`.
5+
#'
6+
#' Invalid dates represent dates made up of valid individual components, which
7+
#' taken as a whole don't represent valid calendar dates. For example, for
8+
#' [year_month_day()] the following component ranges are valid:
9+
#' `year: [-32767, 32767]`, `month: [1, 12]`, `day: [1, 31]`.
10+
#' However, the date `2019-02-31` doesn't exist even though it is made up
11+
#' of valid components. This is an example of an invalid date.
712
#'
813
#' Invalid dates are allowed in clock, provided that they are eventually
914
#' resolved by using `invalid_resolve()` or by manually resolving them through

man/clock-invalid.Rd

Lines changed: 7 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)