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

when using strptime , c_isdst is not store; is this specification? #9

Open
rozary opened this issue Mar 20, 2015 · 1 comment
Open

Comments

@rozary
Copy link

rozary commented Mar 20, 2015

hi.
Please teach me.

BEGIN {
  $ENV{TZ} = "WET"; #Western European Time UTC+0
}
my $t = localtime()->strptime("2015-03-29 00:00:00",'%Y-%m-%d %T' );
say $t; #Sun Mar 29 00:00:00 2015
say $t->isdst; #said 0

$t = localtime()->strptime("2015-03-29 01:00:00",'%Y-%m-%d %T' );
say $t; #Sun Mar 29 02:00:00 2015
say $t->isdst; #said 0. but, i think here is 1.

I think this case, and should be stored.

@smith153
Copy link
Collaborator

strptime() in Time::Piece is not implemented very well, and as you can see isdst is not even set by it. Currently I am working at rewriting strptime() to use pure perl (right now it is made up of C code that was cut and pasted from another library). I do not have an estimated release date, but hopefully before perl 5.24 is released.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants