summaryrefslogtreecommitdiff
path: root/testsuite/tests/deSugar/should_run/dsrun014.hs
diff options
context:
space:
mode:
Diffstat (limited to 'testsuite/tests/deSugar/should_run/dsrun014.hs')
-rw-r--r--testsuite/tests/deSugar/should_run/dsrun014.hs16
1 files changed, 16 insertions, 0 deletions
diff --git a/testsuite/tests/deSugar/should_run/dsrun014.hs b/testsuite/tests/deSugar/should_run/dsrun014.hs
new file mode 100644
index 0000000000..3b08a7ebf0
--- /dev/null
+++ b/testsuite/tests/deSugar/should_run/dsrun014.hs
@@ -0,0 +1,16 @@
+{-# LANGUAGE UnboxedTuples #-}
+
+module Main where
+
+import Debug.Trace
+
+{-# NOINLINE f #-}
+f :: a -> b -> (# a,b #)
+f x y = x `seq` y `seq` (# x,y #)
+
+g :: Int -> Int -> Int
+g v w = case f v w of
+ (# a,b #) -> a+b
+
+main = print (g (trace "one" 1) (trace "two" 2))
+-- The args should be evaluated in the right order!