Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Data.Aeson.Types.Instances: fix UTCTime for years outside of [0, 9999] #200

Merged
merged 1 commit into from
Jul 2, 2014

Conversation

liyang
Copy link
Contributor

@liyang liyang commented May 2, 2014

∙ "take 23" is a dubious way to truncate to millisecond accuracy.
∙ instance ToJSON ZonedTime had it right, so copypasta from it.

*Data.Aeson> import Data.Time
*Data.Aeson Data.Time> encode $ UTCTime (fromGregorian 100000 1 1) 0
"\"100000-01-01T00:00:00.0Z\""

∙ "take 23" is a dubious way to truncate to millisecond accuracy.
∙ instance ToJSON ZonedTime had it right, so copypasta from it.
bos added a commit that referenced this pull request Jul 2, 2014
Data.Aeson.Types.Instances: fix UTCTime for years outside of [0, 9999]
@bos bos merged commit 49a13d2 into haskell:master Jul 2, 2014
@bos
Copy link
Collaborator

bos commented Jul 2, 2014

Thanks.

bos added a commit that referenced this pull request May 11, 2015
Data.Aeson.Types.Instances: fix UTCTime for years outside of [0, 9999]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants