-
Notifications
You must be signed in to change notification settings - Fork 83
Description
Currently https://hackage.haskell.org/package/time-1.8.0.1/docs/Data-Time-Calendar.html#t:Day is represented in memory as an Integer, and many similar functions like fromGregorian which interface with Integers. While this is admirably future-proof (we can deal with years larger than the year 2,147,481,790 AD!) I think we will be using intuitionistic type theory sooner than we will need those dates :)
Using something like Int32 would give us nearly the same flexibility, better Storable instances, interfacing with C and serialization/deserialization. I'm not sure how much this will break downstream code, but I have a feeling most people are using fromIntegral to interface with the API anyways, and this change will actually lessen the amount of marshalling people need to do.