summaryrefslogtreecommitdiff
path: root/testsuite/tests/codeGen/should_run
diff options
context:
space:
mode:
authorAdam Gundry <adam@well-typed.com>2015-10-16 13:58:52 +0100
committerAdam Gundry <adam@well-typed.com>2015-10-16 13:58:52 +0100
commit5a1b4f814f74ec1c48152d97523744518e212777 (patch)
tree7c2207ecacbd37f12c78dbcf9d4334827164e0fb /testsuite/tests/codeGen/should_run
parent6757950cdd8bb0af0355539987ee78401a6a8f6b (diff)
parent808bbdf08058785ae5bc59b5b4f2b04951d4cbbf (diff)
downloadhaskell-wip/orf-reboot.tar.gz
Merge remote-tracking branch 'origin/master' into wip/orf-rebootwip/orf-reboot
Conflicts: compiler/rename/RnNames.hs compiler/typecheck/TcRnMonad.hs utils/haddock
Diffstat (limited to 'testsuite/tests/codeGen/should_run')
-rw-r--r--testsuite/tests/codeGen/should_run/T10870.hs11
-rw-r--r--testsuite/tests/codeGen/should_run/T10870.stdout2
-rw-r--r--testsuite/tests/codeGen/should_run/all.T1
3 files changed, 14 insertions, 0 deletions
diff --git a/testsuite/tests/codeGen/should_run/T10870.hs b/testsuite/tests/codeGen/should_run/T10870.hs
new file mode 100644
index 0000000000..642ef2c1ff
--- /dev/null
+++ b/testsuite/tests/codeGen/should_run/T10870.hs
@@ -0,0 +1,11 @@
+import Data.Bits
+import Data.Int
+import Data.Word
+
+unsafeShift32R :: (Bits a, Num a) => a -> a
+unsafeShift32R x = unsafeShiftR x 32
+
+main :: IO ()
+main = do
+ print $ map unsafeShift32R [ 123456, 0x7fffffff :: Int ]
+ print $ map unsafeShift32R [ 123456, 0xffffffff :: Word ]
diff --git a/testsuite/tests/codeGen/should_run/T10870.stdout b/testsuite/tests/codeGen/should_run/T10870.stdout
new file mode 100644
index 0000000000..945f244e36
--- /dev/null
+++ b/testsuite/tests/codeGen/should_run/T10870.stdout
@@ -0,0 +1,2 @@
+[0,0]
+[0,0]
diff --git a/testsuite/tests/codeGen/should_run/all.T b/testsuite/tests/codeGen/should_run/all.T
index ab2ce60cca..13eda788de 100644
--- a/testsuite/tests/codeGen/should_run/all.T
+++ b/testsuite/tests/codeGen/should_run/all.T
@@ -138,3 +138,4 @@ test('T10414', [only_ways(['threaded2']), extra_ways(['threaded2'])],
compile_and_run, ['-feager-blackholing'])
test('T10521', normal, compile_and_run, [''])
test('T10521b', normal, compile_and_run, [''])
+test('T10870', normal, compile_and_run, [''])