@@ -91,6 +91,7 @@ import Data.Vector (Vector)
9191import Data.Version (Version, showVersion)
9292import Data.Word (Word16, Word32, Word64, Word8)
9393import Foreign.Storable (Storable)
94+import Foreign.C.Types (CTime (..))
9495import GHC.Generics
9596import Numeric.Natural (Natural)
9697import qualified Data.Aeson.Encoding as E
@@ -1366,7 +1367,6 @@ instance ToJSONKey Int64 where
13661367 toJSONKey = toJSONKeyTextEnc E.int64Text
13671368 {-# INLINE toJSONKey #-}
13681369
1369−
13701370instance ToJSON Word where
13711371 toJSON = Number . fromIntegral
13721372 {-# INLINE toJSON #-}
@@ -1426,6 +1426,12 @@ instance ToJSONKey Word64 where
14261426 toJSONKey = toJSONKeyTextEnc E.word64Text
14271427 {-# INLINE toJSONKey #-}
14281428
1429+instance ToJSON CTime where
1430+ toJSON (CTime i) = toJSON i
1431+ {-# INLINE toJSON #-}
1432+
1433+ toEncoding (CTime i) = toEncoding i
1434+ {-# INLINE toEncoding #-}
14291435
14301436instance ToJSON Text where
14311437 toJSON = String