[project @ 1997-03-14 07:52:06 by simonpj]
[ghc-hetmet.git] / ghc / lib / tests / Array / arr009 / Main.hs
1 -- Array - derived ops
2 -- 
3 -- testing the well-behavedness of 
4 -- derived ops for empty and non-empty arrays
5 --
6 import Array
7
8 main = 
9  let 
10   a1 = array (1,0) ([]::[(Int,Int)])
11   a2 = array (1,26) (zip [1..] ['a'..'z'])
12
13   dump a = (bounds a, indices a, elems a, assocs a)
14  in
15  print (dump a1) >>
16  print (dump a2)
17