From 7f2cd04d9c32fb445e2a4513f6bfc34ffc143cee Mon Sep 17 00:00:00 2001 From: simonpj Date: Thu, 9 Mar 2000 13:31:54 +0000 Subject: [PATCH] [project @ 2000-03-09 13:31:54 by simonpj] Add fixity tests --- ghc/tests/numeric/should_run/num010.hs | 13 +++++++++++++ ghc/tests/numeric/should_run/num010.stdout | 1 + 2 files changed, 14 insertions(+) create mode 100644 ghc/tests/numeric/should_run/num010.hs create mode 100644 ghc/tests/numeric/should_run/num010.stdout diff --git a/ghc/tests/numeric/should_run/num010.hs b/ghc/tests/numeric/should_run/num010.hs new file mode 100644 index 0000000..027b5e8 --- /dev/null +++ b/ghc/tests/numeric/should_run/num010.hs @@ -0,0 +1,13 @@ +-- !!! tests that local fixity declarations work + +-- If local fixity decls don't work you get "14" +-- The right answer is "11" + +val = 3 +! 4 *! 2 + where (+!) = (+) + (*!) = (*) + infixl 6 +! + infixl 7 *! + +main = print val + diff --git a/ghc/tests/numeric/should_run/num010.stdout b/ghc/tests/numeric/should_run/num010.stdout new file mode 100644 index 0000000..b4de394 --- /dev/null +++ b/ghc/tests/numeric/should_run/num010.stdout @@ -0,0 +1 @@ +11 -- 1.7.10.4