diff options
Diffstat (limited to 'libraries/ghc-compact/tests/compact_share.hs')
-rw-r--r-- | libraries/ghc-compact/tests/compact_share.hs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/libraries/ghc-compact/tests/compact_share.hs b/libraries/ghc-compact/tests/compact_share.hs index 323c179cca..5dd279cab8 100644 --- a/libraries/ghc-compact/tests/compact_share.hs +++ b/libraries/ghc-compact/tests/compact_share.hs @@ -1,9 +1,10 @@ +import Data.Char import GHC.Compact import qualified Data.Map as Map main = do - let m1 = Map.fromList [(x,show x) | x <- [1..(10000::Integer)]] - m2 = Map.fromList [(x,y) | x <- [1..(10000::Integer)], + let m1 = Map.fromList [(x,show x) | x <- ['a'..chr 10000]] + m2 = Map.fromList [(x,y) | x <- ['a'..chr 10000], Just y <- [Map.lookup x m1]] c <- compact (m1,m2) print (length (show (getCompact c))) |