From 4c7cb1985eb4bcbbb5e3da46d6b445581da10ec9 Mon Sep 17 00:00:00 2001 From: simonmar Date: Wed, 15 Dec 1999 10:01:42 +0000 Subject: [PATCH] [project @ 1999-12-15 10:01:42 by simonmar] Add test displaying bug in fixity resolution on lhs of a function binding. We currently fail on this example, but at least putting it in the test suite will make sure we don't forget about it :) --- ghc/tests/reader/should_compile/read027.hs | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 ghc/tests/reader/should_compile/read027.hs diff --git a/ghc/tests/reader/should_compile/read027.hs b/ghc/tests/reader/should_compile/read027.hs new file mode 100644 index 0000000..c793ca7 --- /dev/null +++ b/ghc/tests/reader/should_compile/read027.hs @@ -0,0 +1,14 @@ +module ShouldCompile where + +infix 5 |- +infix 9 := + +data Equal = Char := Int + +-- fails in GHC 4.04, due to not doing fixity resolution on the lhs +-- before deciding which is the function symbol. + +(|-) :: Int -> Equal -> Bool +0 |- x:=y = 1 |- x:=y -- XXX fails here +2 |- (x:=y) = 0 |- x:=y +_ |- _ = False -- 1.7.10.4