summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Peyton Jones <simonpj@microsoft.com>2013-10-04 18:51:25 +0100
committerSimon Peyton Jones <simonpj@microsoft.com>2013-10-04 18:51:25 +0100
commit5863ce4eb6fe2d7143c483e78b478e25881c0160 (patch)
treebd59ccc337e60404c600c2ba7ddeb0fa01146f98
parent4462992588c4c92bdb07d7e321e7efa1aafb990c (diff)
downloadhaskell-5863ce4eb6fe2d7143c483e78b478e25881c0160.tar.gz
Test Trac #8383
-rw-r--r--testsuite/tests/ghci/scripts/T8383.hs8
-rw-r--r--testsuite/tests/ghci/scripts/T8383.script3
-rw-r--r--testsuite/tests/ghci/scripts/T8383.stdout2
-rwxr-xr-xtestsuite/tests/ghci/scripts/all.T2
4 files changed, 15 insertions, 0 deletions
diff --git a/testsuite/tests/ghci/scripts/T8383.hs b/testsuite/tests/ghci/scripts/T8383.hs
new file mode 100644
index 0000000000..44ef0feac8
--- /dev/null
+++ b/testsuite/tests/ghci/scripts/T8383.hs
@@ -0,0 +1,8 @@
+{-# LANGUAGE MagicHash #-}
+module T8383 where
+import GHC.Exts
+f :: Int# -> Int#
+f x = x
+foo = print $ (tagToEnum# (f 0#) :: Bool)
+bar = print $ (tagToEnum# (f 1#) :: Bool)
+
diff --git a/testsuite/tests/ghci/scripts/T8383.script b/testsuite/tests/ghci/scripts/T8383.script
new file mode 100644
index 0000000000..5d43f29ac6
--- /dev/null
+++ b/testsuite/tests/ghci/scripts/T8383.script
@@ -0,0 +1,3 @@
+:l T8383
+foo
+bar
diff --git a/testsuite/tests/ghci/scripts/T8383.stdout b/testsuite/tests/ghci/scripts/T8383.stdout
new file mode 100644
index 0000000000..91d6f80f27
--- /dev/null
+++ b/testsuite/tests/ghci/scripts/T8383.stdout
@@ -0,0 +1,2 @@
+False
+True
diff --git a/testsuite/tests/ghci/scripts/all.T b/testsuite/tests/ghci/scripts/all.T
index d5b9e2cf05..9a278ef00f 100755
--- a/testsuite/tests/ghci/scripts/all.T
+++ b/testsuite/tests/ghci/scripts/all.T
@@ -156,3 +156,5 @@ test('T8113', normal, ghci_script, ['T8113.script'])
test('T8172', normal, ghci_script, ['T8172.script'])
test('T8215', normal, ghci_script, ['T8215.script'])
test('T8357', normal, ghci_script, ['T8357.script'])
+test('T8383', normal, ghci_script, ['T8383.script'])
+