From bd387bc1e9bb8ceb5fcb4619b85d38d7fdb2a9b8 Mon Sep 17 00:00:00 2001 From: simonm Date: Fri, 7 Aug 1998 15:22:03 +0000 Subject: [PATCH] [project @ 1998-08-07 15:22:02 by simonm] add regression test for bug in mkDupableAlt. --- ghc/tests/simplCore/should_compile/simpl004.hs | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 ghc/tests/simplCore/should_compile/simpl004.hs create mode 100644 ghc/tests/simplCore/should_compile/simpl004.stderr diff --git a/ghc/tests/simplCore/should_compile/simpl004.hs b/ghc/tests/simplCore/should_compile/simpl004.hs new file mode 100644 index 0000000..0008ae1 --- /dev/null +++ b/ghc/tests/simplCore/should_compile/simpl004.hs @@ -0,0 +1,18 @@ +{-# OPTIONS -fglasgow-exts #-} + +module ShouldCompile where + +import Ix +import GlaExts + + +f ixs@(_, ix_end) frozen# = + let + n# = + case ( + if null (range ixs) + then 0 + else 1 + ) of { I# x -> x } + in + (# frozen#, False #) diff --git a/ghc/tests/simplCore/should_compile/simpl004.stderr b/ghc/tests/simplCore/should_compile/simpl004.stderr new file mode 100644 index 0000000..e69de29 -- 1.7.10.4