qntm / t-a-i

Converts Unix milliseconds to and from International Atomic Time (TAI) milliseconds
MIT License
43 stars 2 forks source link

Streamlined internals #33

Closed qntm closed 2 years ago

qntm commented 2 years ago

Follows #32. Part of a series of operations to make it possible to use t-a-i with the Temporal API.

Internally, we now use precise Rats everywhere, right from when we first parse the source data table and/or when the consumer passes millisecond counts to us. Segment is now passed a ratio unixPerAtomic instead of separate dy and dx values - one measured in picoseconds and one in milliseconds, making things very pleasant. This allows a lot of streamlining but it will also soon allow me to expose new Rat-based APIs for conversions.