in reply to Re^2: Converting epoch times after 2038
in thread Converting epoch times after 2038
Be careful with that on 32-bit platforms, since on 32-bit platforms 1 << 33 will be 2
... when perl is not built with 64-bit integer support (here it is "v5.8.8 built for i386-freebsd-64int" (32 bit architecture)) ...
perl -we 'print map { sprintf "%d %d\n" , $_ , ( 1 << $_ ) } ( 30 .. +34 , 60 .. 65 ) ' 30 1073741824 31 2147483648 32 4294967296 33 8589934592 34 17179869184 60 1152921504606846976 61 2305843009213693952 62 4611686018427387904 63 -9223372036854775808 64 1 65 2
|
|---|