Commit ea6dcef1 authored by Simon Peyton Jones's avatar Simon Peyton Jones
Browse files

Test Trac #8832

The test is a bit crude; -ddump-simpl | grep '#'.

I'm concerned that the -ddump-simpl output may differ on 32 and 64-bit
platforms.  So far I've only put in output for 64-bit platforms.
parent 8fd7d581
......@@ -2,6 +2,10 @@ TOP=../../..
include $(TOP)/mk/boilerplate.mk
include $(TOP)/mk/test.mk
T8832:
$(RM) -f T8832.o T8832.hi
'$(TEST_HC)' $(TEST_HC_OPTS) -O -c -ddump-simpl T8832.hs | grep '#'
T7865:
$(RM) -f T7865.o T7865.hi
'$(TEST_HC)' $(TEST_HC_OPTS) -dsuppress-uniques -O2 -c -ddump-simpl T7865.hs | grep expensive
......
{-# LANGUAGE CPP #-}
-- I'm concerned that the -ddump-simpl output may differ on 32 and 64-bit
-- platforms. So far I've only put in output for 64-bit platforms.
module T8832 where
import Data.Bits
import Data.Int
import Data.Word
#define T(s,T) \
s :: T ; \
s = clearBit (bit 0) 0 ; \
T(i,Int)
T(i8,Int8)
T(i16,Int16)
T(i32,Int32)
T(i64,Int64)
T(w,Word)
T(w8,Word8)
T(w16,Word16)
T(w32,Word32)
T(w64,Word64)
T(z,Integer)
\ No newline at end of file
T8832.i = GHC.Types.I# 0
T8832.i8 = GHC.Int.I8# 0
T8832.i16 = GHC.Int.I16# 0
T8832.i32 = GHC.Int.I32# 0
T8832.i64 = GHC.Int.I64# 0
T8832.w = GHC.Types.W# (__word 0)
T8832.w8 = GHC.Word.W8# (__word 0)
T8832.w16 = GHC.Word.W16# (__word 0)
T8832.w32 = GHC.Word.W32# (__word 0)
T8832.w64 = GHC.Word.W64# (__word 0)
......@@ -198,4 +198,7 @@ test('T5996',
run_command,
['$MAKE -s --no-print-directory T5996'])
test('T8537', normal, compile, [''])
test('T8714', normal, compile, [''])
test('T8832',
extra_clean(['T8832.hi', 'T8832a.o']),
run_command,
['$MAKE -s --no-print-directory T8832'])
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment