Fix Data.Fixed.Fixed's Read instance; fixes #7483
[ghc.git] / libraries / base / tests / readFixed001.hs
1
2 import Data.Fixed
3
4 main :: IO ()
5 main = do f " (( ( 12.3456 ) ) ) "
6 f " (( ( 12.3 ) ) ) "
7 f " (( ( 12. ) ) ) "
8 f " (( ( 12 ) ) ) "
9 f " (( - ( 12.3456 ) ) ) "
10 f " (( ( -12.3456 ) ) ) "
11
12 f :: String -> IO ()
13 f str = print (reads str :: [(Centi, String)])