# New Ticket Created by  Zoffix Znet 
# Please include the string:  [perl #130123]
# in the subject line of all future correspondence about this issue. 
# <URL: https://rt.perl.org/Ticket/Display.html?id=130123 >



The Instant.from-posix adds leap seconds to the provided argument:

     <ZoffixW> m: say Instant.from-posix: 99999990
     <camelia> rakudo-moar 2432c4: OUTPUT«Instant:100000002␤»

And if you give low-enough values, you'll notice there's a special  
value of 10 seconds that's added regardless of what the given argument  
is:

     <ZoffixW> m: say Instant.from-posix: 0
     <camelia> rakudo-moar 2432c4: OUTPUT«Instant:10␤»
     <ZoffixW> m: say Instant.from-posix: -1010
     <camelia> rakudo-moar 2432c4: OUTPUT«Instant:-1000␤»
     <ZoffixW> m: say Instant.from-posix: 10000
     <camelia> rakudo-moar 2432c4: OUTPUT«Instant:10010␤»

However, it appears those 10 extra seconds are not supposed to be  
there prior to the start of 1972 (I've not yet found the exact moment  
in time).

 From Wikipedia's aticle on TAI[^1]:

     TAI is exactly 36 seconds ahead of UTC. The 36 seconds results  
from the *****initial difference of 10 seconds at the start of  
1972*****, plus 26 leap seconds in UTC since 1972.

So to me, it appears like the method must not add those extra 10  
seconds for anything prior to some specific time in 1972.



[1] https://en.wikipedia.org/wiki/International_Atomic_Time

Reply via email to