From 4a9e925e23ad8d78da1066384882160400ef0486 Mon Sep 17 00:00:00 2001 From: simonmar Date: Wed, 3 Jan 2001 11:32:33 +0000 Subject: [PATCH] [project @ 2001-01-03 11:32:33 by simonmar] Add a test for mixing unlifted types w/ polymorphic functions. --- ghc/tests/typecheck/should_fail/tcfail090.hs | 8 ++++++++ ghc/tests/typecheck/should_fail/tcfail090.stderr | 7 +++++++ 2 files changed, 15 insertions(+) create mode 100644 ghc/tests/typecheck/should_fail/tcfail090.hs create mode 100644 ghc/tests/typecheck/should_fail/tcfail090.stderr diff --git a/ghc/tests/typecheck/should_fail/tcfail090.hs b/ghc/tests/typecheck/should_fail/tcfail090.hs new file mode 100644 index 0000000..3d8fc12 --- /dev/null +++ b/ghc/tests/typecheck/should_fail/tcfail090.hs @@ -0,0 +1,8 @@ +{-# OPTIONS -fglasgow-exts #-} + +module ShouldFail where + +import PrelGHC + +die :: Int -> ByteArray# +die _ = undefined diff --git a/ghc/tests/typecheck/should_fail/tcfail090.stderr b/ghc/tests/typecheck/should_fail/tcfail090.stderr new file mode 100644 index 0000000..8b011a2 --- /dev/null +++ b/ghc/tests/typecheck/should_fail/tcfail090.stderr @@ -0,0 +1,7 @@ + +tcfail090.hs:8: + Couldn't match `#' against `*' + When matching types `ByteArray#' and `a' + Expected type: ByteArray# + Inferred type: a + In the right-hand side of an equation for `die': undefined -- 1.7.10.4