Re: [PATCH] Call timegm and timelocal with 4-digit year

2018-02-26 Thread Bernhard M. Wiedemann
On 2018-02-24 23:28, Ævar Arnfjörð Bjarmason wrote: > My Time::Local 1.2300 on perl 5.024001 currently interprets "69" here as > 1969, but after this it'll be 2069. on one hand, there is already perl -e 'use Time::Local; print scalar gmtime(Time::Local::timegm(0,0,0,1,0,68))' Sun Jan 1

Re: [PATCH] Call timegm and timelocal with 4-digit year

2018-02-24 Thread Ævar Arnfjörð Bjarmason
On Fri, Feb 23 2018, Bernhard M. Wiedemann jotted: > amazingly timegm(gmtime(0)) is only 0 before 2020 > because perl's timegm deviates from GNU timegm(3) in how it handles years. > > man Time::Local says > > Whenever possible, use an absolute four digit year instead. > > with a detailed

Re: [PATCH] Call timegm and timelocal with 4-digit year

2018-02-23 Thread Junio C Hamano
"Bernhard M. Wiedemann" writes: > amazingly timegm(gmtime(0)) is only 0 before 2020 > because perl's timegm deviates from GNU timegm(3) in how it handles years. > > man Time::Local says > > Whenever possible, use an absolute four digit year instead. > > with a detailed

[PATCH] Call timegm and timelocal with 4-digit year

2018-02-23 Thread Bernhard M. Wiedemann
amazingly timegm(gmtime(0)) is only 0 before 2020 because perl's timegm deviates from GNU timegm(3) in how it handles years. man Time::Local says Whenever possible, use an absolute four digit year instead. with a detailed explanation about ambiguity of 2-digit years above that. Even though