Commit 8b471a8c authored by simonpj's avatar simonpj
Browse files

[project @ 2004-10-01 13:58:37 by simonpj]

Update expected output for new GADT-enabled typechecker
parent 42050ebb
drvfail001.hs:15:5:
No instance for (Show (f (f a)))
arising from the data type declaration at drvfail001.hs:15:5
arising from the 'deriving' clause of a data type declaration at drvfail001.hs:15:5
When deriving the `Show' instance for type `SM'
drvfail001.hs:21:5:
No instance for (Show (f a))
arising from the data type declaration at drvfail001.hs:21:5
arising from the 'deriving' clause of a data type declaration at drvfail001.hs:21:5
When deriving the `Show' instance for type `Cons'
drvfail003.hs:13:5:
No instance for (Show (v (v a)))
arising from the data type declaration at drvfail003.hs:13:5
arising from the 'deriving' clause of a data type declaration at drvfail003.hs:13:5
When deriving the `Show' instance for type `Square_'
drvfail004.hs:5:5:
Could not deduce (Eq (Foo a b)) from the context (Ord a, Ord b)
arising from the instance declaration at drvfail004.hs:5:5
arising from the superclasses of an instance declaration at drvfail004.hs:5:5
Probable fix:
Add (Eq (Foo a b)) to the instance declaration superclass context
Or add an instance declaration for (Eq (Foo a b))
......
drvfail007.hs:4:5:
No instance for (Eq (Int -> Int))
arising from the data type declaration at drvfail007.hs:4:5
arising from the 'deriving' clause of a data type declaration at drvfail007.hs:4:5
When deriving the `Eq' instance for type `Foo'
mod46.hs:4:0:
No instance for (Eq T)
arising from the instance declaration at mod46.hs:4:0
arising from the superclasses of an instance declaration at mod46.hs:4:0
In the instance declaration for `Ord T'
mod47.hs:6:0:
Could not deduce (Num a) from the context (Eq a, Enum a)
arising from the instance declaration at mod47.hs:6:0
arising from the superclasses of an instance declaration at mod47.hs:6:0
Probable fix: Add (Num a) to the instance declaration superclass context
In the instance declaration for `Bar [a]'
mod54.hs:3:5:
No instance for (Eq T)
arising from the instance declaration at mod54.hs:3:5
arising from the superclasses of an instance declaration at mod54.hs:3:5
In the instance declaration for `Ord T'
mod60.hs:3:3:
Constructor `Left' should have 1 argument, but has been given 0
When checking the pattern: Left
In the definition of `f': f (Left) = error "foo"
read003.hs:4:26:
Occurs check: cannot construct the infinite type: t = (t, [a], t1)
Expected type: (t, [a], t1)
Inferred type: t
Occurs check: cannot construct the infinite type: a = (a, [a], c)
Expected type: (a, [a], c)
Inferred type: a
In the right-hand side of a pattern binding: a
In a pattern binding:
~(a, b, c)
......
......@@ -8,5 +8,5 @@ test('simpl005', normal, compile, [''])
# test('simpl006', normal, compile, [''])
test('simpl007', normal, compile, [''])
test('simpl008', normal, compile, ['-fglasgow-exts'])
test('simpl008', normal, compile_fail, [''])
test('simpl009', normal, compile, [''])
import GHC.Exts
{-# OPTIONS -fglasgow-exts #-}
-- Should fail, because f :: (# Int#, ByteArray# #)
import GHC.Prim
main :: IO ()
main = let f = int2Integer# 0# in putStrLn ""
......
simpl008.hs:8:15:
Couldn't match kind `??' against `(#)'
When matching the kinds of `t :: ??' and `(# Int#, ByteArray# #) :: (#)'
Expected type: t
Inferred type: (# Int#, ByteArray# #)
In the application `int2Integer# 0#'
LetE [ValD (VarP foo_0) (NormalB (VarE bar_1)) [ValD (VarP bar_1) (NormalB (LitE (IntegerL 3))) []]] (VarE foo_0)
......@@ -5,6 +5,9 @@
-- in the pattern matching compiler, so they are a bit
-- tricky.
-- GHC 6.3: these are back to failures, because we no longer do
-- type subsumption in pattern-matching
module ShouldCompile where
newtype Bug s a = Bug a
......
tc162.hs:16:8:
Couldn't match `forall s. Bug s a' against `Bug s a1'
In the definition of `runBug': runBug (Bug _) = undefined
tc162.hs:21:9:
Couldn't match `forall s. BugN s a' against `BugN s a1'
In the definition of `runBugN': runBugN (BugN _) = undefined
tc162.hs:26:7:
Couldn't match `forall a b. Foo a b' against `Foo a b'
In the definition of `baz': baz s (Foo {foo = foo}) = putStrLn s
tcfail001.hs:9:7:
tcfail001.hs:9:1:
Couldn't match `[a]' against `t -> t1'
Expected type: [a]
Inferred type: t -> t1
In the definition of `op': op [] = []
In the definition for method `op'
In the instance declaration for `A [a]'
tcfail004.hs:3:8:
Couldn't match `(t, t1)' against `(t2, t3, t4)'
Expected type: (t, t1)
Inferred type: (t2, t3, t4)
Couldn't match `(a, b)' against `(a1, b1, c)'
Expected type: (a, b)
Inferred type: (a1, b1, c)
In a pattern binding: (f, g) = (1, 2, 3)
tcfail005.hs:3:8:
Couldn't match `[a]' against `(t, t1)'
Expected type: [a]
Inferred type: (t, t1)
Couldn't match `[a]' against `(a1, b)'
Expected type: [a]
Inferred type: (a1, b)
In a pattern binding: (h : i) = (1, 'a')
tcfail013.hs:4:2:
Couldn't match `Bool' against `[a]'
Expected type: Bool
Inferred type: [a]
Couldn't match `[a]' against `Bool'
Expected type: [a]
Inferred type: Bool
When checking the pattern: True
In the definition of `f': f True = 2
tcfail017.hs:10:0:
Could not deduce (C [a]) from the context (B a)
arising from the instance declaration at tcfail017.hs:10:0
arising from the superclasses of an instance declaration at tcfail017.hs:10:0
Probable fix:
Add (C [a]) to the instance declaration superclass context
Or add an instance declaration for (C [a])
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment