Skip to content

Commit 82527e7

Browse files
committed
as.POSIXlt.date_xx and as.POSIXct.date_xx now set UTC timezone by default (for compat with new as.POSIXct.Date)
1 parent 2128723 commit 82527e7

File tree

4 files changed

+8
-7
lines changed

4 files changed

+8
-7
lines changed

DESCRIPTION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ Type: Package
22
Package: dint
33
Title: A Toolkit for Year-Quarter, Year-Month and Year-Isoweek
44
Dates
5-
Version: 2.1.3.9001
5+
Version: 2.1.4
66
Authors@R:
77
person(given = "Stefan",
88
family = "Fleck",

NEWS.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,11 @@
1-
# dint (dev version)
1+
# dint 2.1.4
22

33
* vectors of length 1 are now recycled when adding or subtracting `date_xx`
44
objects, e.g. `date_yq(2019, 1) + 1:4` is now possible (#5).
55
* `qy` can now handle inputs without seperator between quarter and year
66
(e.g. `myfile42019`)
7+
* `as.POSIXlt.date_xx()` and `as.POSIXct.date_xx()` now set UTC timezone by
8+
default (for compatibility with `as.POSIXct.Date()` changes in latest R version)
79

810

911
# dint 2.1.3

R/date_xx.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ NULL
133133
#' @rdname as.Date.date_xx
134134
#' @inheritParams base::as.POSIXlt
135135
#' @export
136-
as.POSIXlt.date_xx <- function(x, tz = "", ...){
136+
as.POSIXlt.date_xx <- function(x, tz = "UTC", ...){
137137
as.POSIXlt(as.Date(x), tz = tz, ...)
138138
}
139139

@@ -143,7 +143,7 @@ as.POSIXlt.date_xx <- function(x, tz = "", ...){
143143
#' @rdname as.Date.date_xx
144144
#' @inheritParams base::as.POSIXlt
145145
#' @export
146-
as.POSIXct.date_xx <- function(x, tz = "", ...){
146+
as.POSIXct.date_xx <- function(x, tz = "UTC", ...){
147147
as.POSIXct(as.Date(x, tz = tz), tz = tz, ...)
148148
}
149149

cran-comments.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,5 @@
1010

1111
## submission
1212

13-
Correct a small error in the documentation of `date_xx_arithmetic` that
14-
triggers a CRAN Warning since the fixing of
15-
https://bugs.r-project.org/bugzilla/show_bug.cgi?id=16223>
13+
Update `as.POSIXlt.date_xx()` and `as.POSIXct.date_xx()` to be consistent with
14+
tzone behaviour of `as.POSIXct.Date()` and `as.POSIXlt.Date()` in R-devel

0 commit comments

Comments
 (0)