From 2c3ba31262831d8d7a74a1d22543ecd990504801 Mon Sep 17 00:00:00 2001 From: simonpj Date: Mon, 26 Jul 1999 16:01:51 +0000 Subject: [PATCH] [project @ 1999-07-26 16:01:51 by simonpj] Add read009, do-notation --- ghc/tests/reader/should_fail/read009.hs | 15 +++++++++++++++ ghc/tests/reader/should_fail/read009.stderr | 3 +++ 2 files changed, 18 insertions(+) create mode 100644 ghc/tests/reader/should_fail/read009.hs create mode 100644 ghc/tests/reader/should_fail/read009.stderr diff --git a/ghc/tests/reader/should_fail/read009.hs b/ghc/tests/reader/should_fail/read009.hs new file mode 100644 index 0000000..4642897 --- /dev/null +++ b/ghc/tests/reader/should_fail/read009.hs @@ -0,0 +1,15 @@ +module ShouldFail where + +-- !!! Do-notation requires an *expression* at the end. + +foo = do let foo = True + return () + + +-- Note the let binding at the end! +-- This gave a pattern-match failure in tcStmts in ghc-4.04proto + +h x = x + + + diff --git a/ghc/tests/reader/should_fail/read009.stderr b/ghc/tests/reader/should_fail/read009.stderr new file mode 100644 index 0000000..249a080 --- /dev/null +++ b/ghc/tests/reader/should_fail/read009.stderr @@ -0,0 +1,3 @@ +This current error message is rather unhelpful: + + read009.hs:12: parse error on input `' -- 1.7.10.4