1{-# OPTIONS_GHC -fsimpl-tick-factor=0 #-}
2module Main (main) where
8import Data.Aeson (decode, encode)
9import Data.Time.Clock (UTCTime)
10import Data.Time.LocalTime (ZonedTime)
11import qualified Data.ByteString.Lazy as BL
13utcTime :: BL.ByteString -> Maybe [UTCTime]
16zTime :: BL.ByteString -> Maybe [ZonedTime]
21 let file1 = BL.readFile "json-data/dates.json"
22 let file2 = BL.readFile "json-data/dates-fract.json"
26 env file1 $ \bs -> bench "whole" $ nf utcTime bs
27 , env file2 $ \bs -> bench "fractional" $ nf utcTime bs
29 , bgroup "ZonedTime" [
30 env file1 $ \bs -> bench "whole" $ nf zTime bs
31 , env file2 $ \bs -> bench "fractional" $ nf zTime bs
36 env (utcTime <$> file1) $ \ts -> bench "whole" $ nf encode ts
37 , env (utcTime <$> file2) $ \ts -> bench "fractional" $ nf encode ts
39 , bgroup "ZonedTime" [
40 env (zTime <$> file1) $ \ts -> bench "whole" $ nf encode ts
41 , env (zTime <$> file2) $ \ts -> bench "fractional" $ nf encode ts
keysesc to close
- j k
- move down, up
- enter
- open
- esc
- back, or up a level
- 1 2 3 4
- readme, files, commits, refs
- /
- filter
- y
- copy the clone command
- c
- compare the chosen commit with another (or shift-click both)
- ?
- show or hide this list