Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fast IDate/Time methods for UTC can be extended to when we can infer tz is UTC #4116

Closed
MichaelChirico opened this issue Dec 16, 2019 · 0 comments · Fixed by #4117
Closed

fast IDate/Time methods for UTC can be extended to when we can infer tz is UTC #4116

MichaelChirico opened this issue Dec 16, 2019 · 0 comments · Fixed by #4117
Assignees
Milestone

Comments

@MichaelChirico
Copy link
Member

@MichaelChirico MichaelChirico commented Dec 16, 2019

Currently we test:

if (inherits(x, "POSIXct") && identical(attr(x, "tzone", exact = TRUE), "UTC")) 

However, if 'tzone' attribute is missing and Sys.timezone() is UTC (actually, %chin% c('GMT', 'UTC', 'Etc/UTC', 'Etc/GMT', 'GMT-0', 'GMT+0', 'GMT0') is fine), we can do the same shortcut

@MichaelChirico MichaelChirico self-assigned this Dec 16, 2019
@mattdowle mattdowle added this to the 1.12.9 milestone Dec 16, 2019
@jangorecki jangorecki removed this from the 1.12.11 milestone May 26, 2020
@jangorecki jangorecki added this to the 1.12.9 milestone May 26, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants