From: sof Date: Mon, 15 Feb 1999 17:57:30 +0000 (+0000) Subject: [project @ 1999-02-15 17:57:29 by sof] X-Git-Tag: Approximately_9120_patches~6548 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=ca56dadacc0b8dbeb76fe2417f676b9a83221235;p=ghc-hetmet.git [project @ 1999-02-15 17:57:29 by sof] Empty export list regression test --- diff --git a/ghc/tests/reader/should_compile/Makefile b/ghc/tests/reader/should_compile/Makefile index 965c885..71d1bba 100644 --- a/ghc/tests/reader/should_compile/Makefile +++ b/ghc/tests/reader/should_compile/Makefile @@ -7,5 +7,6 @@ SRC_HC_OPTS += -noC -dcore-lint read004_HC_OPTS = -fno-implicit-prelude read012_HC_OPTS += -O -funfold-casms-in-hi-file -fglasgow-exts read013_HC_OPTS += -O -funfold-casms-in-hi-file -fglasgow-exts +read014_HC_OPTS += -Wall include $(TOP)/mk/target.mk diff --git a/ghc/tests/reader/should_compile/read014.hs b/ghc/tests/reader/should_compile/read014.hs new file mode 100644 index 0000000..b8bfe7f --- /dev/null +++ b/ghc/tests/reader/should_compile/read014.hs @@ -0,0 +1,8 @@ +-- !!! Empty export lists are legal (and useful.) +module T () where + +ng1 x y = negate y + +instance (Num a, Num b) => Num (a,b) + where + negate (a,b) = (ng 'c' a, ng1 'c' b) where ng x y = negate y diff --git a/ghc/tests/reader/should_compile/read014.stderr b/ghc/tests/reader/should_compile/read014.stderr new file mode 100644 index 0000000..1a4da3b --- /dev/null +++ b/ghc/tests/reader/should_compile/read014.stderr @@ -0,0 +1,30 @@ + +read014.hs:2: Warning: definition but no type signature for `ng1' + +read014.hs:4: Warning: Defined but not used: x + +read014.hs:8: Warning: Defined but not used: x + + + +read014.hs:8: + Warning: No explicit method nor default method for `fromInteger' + in an instance declaration for `Num' + +read014.hs:8: + Warning: No explicit method nor default method for `signum' + in an instance declaration for `Num' + +read014.hs:8: + Warning: No explicit method nor default method for `abs' + in an instance declaration for `Num' + +read014.hs:8: + Warning: No explicit method nor default method for `*' + in an instance declaration for `Num' + +read014.hs:8: + Warning: No explicit method nor default method for `+' + in an instance declaration for `Num' + +