summaryrefslogtreecommitdiff
path: root/testsuite/tests/array/should_run/arr008.hs
diff options
context:
space:
mode:
Diffstat (limited to 'testsuite/tests/array/should_run/arr008.hs')
-rw-r--r--testsuite/tests/array/should_run/arr008.hs14
1 files changed, 14 insertions, 0 deletions
diff --git a/testsuite/tests/array/should_run/arr008.hs b/testsuite/tests/array/should_run/arr008.hs
new file mode 100644
index 0000000000..14152c5a9d
--- /dev/null
+++ b/testsuite/tests/array/should_run/arr008.hs
@@ -0,0 +1,14 @@
+-- !!! Array - out-of-range (index,value) pairs
+--
+-- supplying a list containing one or more pairs
+-- with out-of-range index is undefined.
+--
+--
+import Data.Array
+
+main =
+ let
+ a1 = array (1::Int,0) []
+ a2 = array (0::Int,1) (zip [0..] ['a'..'z'])
+ in
+ print (a1::Array Int Int) >> print a2