Commit 9e71989b authored by Ian Lynagh's avatar Ian Lynagh
Browse files

Add a test for Data.Map, for a bug on the libraries@ list

parent d6b1060c
# This Makefile runs the tests using GHC's testsuite framework. It
# assumes the package is part of a GHC build tree with the testsuite
# installed in ../../../testsuite.
TOP=../../../testsuite
include $(TOP)/mk/boilerplate.mk
include $(TOP)/mk/test.mk
# This is a test script for use with GHC's testsuite framework, see
# http://darcs.haskell.org/testsuite
test('datamap001', normal, compile_and_run, [''])
{-
In the 6.6 era this printed [(5,"x")]; should be [(3,"b"),(5,"a")]
-}
module Main (main) where
import Data.Map
main :: IO ()
main = do let m = fromList [(3,"b"),(5,"a")]
f k a = Just "x"
m' = updateAt f 1 m
print m'
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment