Added Unknowns for higher kinds
authorPepe Iborra <mnislaih@gmail.com>
Wed, 8 Nov 2006 15:59:38 +0000 (15:59 +0000)
committerPepe Iborra <mnislaih@gmail.com>
Wed, 8 Nov 2006 15:59:38 +0000 (15:59 +0000)
GHC/Base.lhs
GHC/Exts.hs
GHC/Show.lhs

index 2b79b78..4fc09a6 100644 (file)
@@ -732,6 +732,12 @@ breakpointCond :: Bool -> a -> a
 breakpointCond _ r = r
 
 data Unknown 
+data Unknown1 a
+data Unknown2 a b
+data Unknown3 a b c
+data Unknown4 a b c d
+
+data Opaque = forall a. O a
 
 -- | Constant function.
 const                  :: a -> b -> a
index 7b850d4..20f43ef 100644 (file)
@@ -29,7 +29,7 @@ module GHC.Exts
        Splittable(..),
 
        -- * Debugging
-       breakpoint, breakpointCond, Unknown,
+       breakpoint, breakpointCond, Unknown, Unknown2, Unknown3, Unknown4,
 
        -- * Ids with special behaviour
        lazy, inline,
index 06fddd8..85d4c7d 100644 (file)
@@ -423,4 +423,21 @@ itos n# cs
 instance Show Unknown where
  show _ = "This is an untyped, unevaluated computation. You can use seq to force its evaluation and then :print to recover its type"
  showList _ = ("This is an untyped, unevaluated computation. You can use seq to force its evaluation and then :print to recover its type" ++)
+
+instance Show (Unknown1 a) where
+ show _ = "This is an untyped, unevaluated computation. You can use seq to force its evaluation and then :print to recover its type"
+ showList _ = ("This is an untyped, unevaluated computation. You can use seq to force its evaluation and then :print to recover its type" ++)
+
+instance Show (Unknown2 a b) where
+ show _ = "This is an untyped, unevaluated computation. You can use seq to force its evaluation and then :print to recover its type"
+ showList _ = ("This is an untyped, unevaluated computation. You can use seq to force its evaluation and then :print to recover its type" ++)
+
+instance Show (Unknown3 a b c) where
+ show _ = "This is an untyped, unevaluated computation. You can use seq to force its evaluation and then :print to recover its type"
+ showList _ = ("This is an untyped, unevaluated computation. You can use seq to force its evaluation and then :print to recover its type" ++)
+
+instance Show (Unknown4 a b c d) where
+ show _ = "This is an untyped, unevaluated computation. You can use seq to force its evaluation and then :print to recover its type"
+ showList _ = ("This is an untyped, unevaluated computation. You can use seq to force its evaluation and then :print to recover its type" ++)
+
 \end{code}
\ No newline at end of file