Skip to content

Commit

Permalink
Bump version
Browse files Browse the repository at this point in the history
  • Loading branch information
bos committed Apr 13, 2011
1 parent ca20520 commit 86433ea
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
2 changes: 1 addition & 1 deletion aeson.cabal
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: aeson
version: 0.3.2.3
version: 0.3.2.4
license: BSD3
license-file: LICENSE
category: Text, Web, JSON
Expand Down
7 changes: 5 additions & 2 deletions tests/Properties.hs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE OverloadedStrings, ScopedTypeVariables #-}

import Data.Aeson.Encode
import Data.Aeson.Parser (value)
Expand All @@ -11,7 +11,10 @@ import Test.QuickCheck.Monadic (assert, monadicIO, run)
import qualified Data.ByteString.Lazy.Char8 as L
import qualified Data.Attoparsec.Lazy as L

encodeDouble d = encode (Number (D d)) == L.pack (show d)
encodeDouble num denom
| isInfinite d || isNaN d = encode (Number (D d)) == "null"
| otherwise = encode (Number (D d)) == L.pack (show d)
where d = num / denom
encodeInteger i = encode (Number (I i)) == L.pack (show i)

roundTrip :: (Eq a, FromJSON a, ToJSON a) => a -> Bool
Expand Down

0 comments on commit 86433ea

Please sign in to comment.