From dabf228557652cff050924cdc669450c0ece0f76 Mon Sep 17 00:00:00 2001 From: lewie Date: Wed, 11 Apr 2001 18:10:16 +0000 Subject: [PATCH] [project @ 2001-04-11 18:10:16 by lewie] Add implicit param test. --- ghc/tests/typecheck/should_compile/tc121.hs | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 ghc/tests/typecheck/should_compile/tc121.hs diff --git a/ghc/tests/typecheck/should_compile/tc121.hs b/ghc/tests/typecheck/should_compile/tc121.hs new file mode 100644 index 0000000..461058e --- /dev/null +++ b/ghc/tests/typecheck/should_compile/tc121.hs @@ -0,0 +1,18 @@ +{-# OPTIONS -fglasgow-exts #-} + +-- Implicit Parameters + +-- If the implicit param isn't recognized as a PredType, x and y +-- will be inferred to have two params instead of one. + +module ShouldCompile where + +x () = ?wibble + +y () = x () + +same :: a -> a -> b +same x y = undefined + +a () = same x id +b () = same y id -- 1.7.10.4