Commit b504edb3 authored by simonpj's avatar simonpj
Browse files

[project @ 2002-11-28 17:21:00 by simonpj]

Update expected output for new type-error generation
parent 85630e62
......@@ -99,3 +99,4 @@ test('tcfail109', normal, compile_fail, [''])
test('tcfail110', normal, compile_fail, [''])
test('tcfail111', normal, compile_fail, [''])
test('tcfail112', normal, compile_fail, [''])
test('tcfail113', normal, compile_fail, [''])
tcfail003.hs:3:
No instance for (Num Char)
arising from the literal `1' at tcfail003.hs:3
arising from the literal `1' at tcfail003.hs:3
In the list element: 1
In the right-hand side of a pattern binding: [1, 'a']
In a pattern binding: (d : e) = [1, 'a']
tcfail006.hs:5:
No instance for (Num Bool)
arising from the literal `1' at tcfail006.hs:5
arising from the literal `1' at tcfail006.hs:5
In the body of a case alternative: (1, True)
In a case alternative: False -> (1, True)
In the case expression:
case (if True then True else False) of
True -> (True, 1)
False -> (1, True)
tcfail008.hs:3:
No instance for (Num [a])
arising from the literal `2' at tcfail008.hs:3
arising from the literal `2' at tcfail008.hs:3
Possible cause: the monomorphism restriction applied to the following:
o :: [a] (bound at tcfail008.hs:3)
In the second argument of `(:)', namely `2'
In a right-hand side of function `o': 1 : 2
In the definition of `o': o = 1 : 2
tcfail010.hs:3:
No instance for (Num [a])
arising from use of `+' at tcfail010.hs:3
arising from use of `+' at tcfail010.hs:3
Possible cause: the monomorphism restriction applied to the following:
q :: [a] -> [a] (bound at tcfail010.hs:3)
In the body of a lambda: z + 2
In a lambda abstraction: \ (y : z) -> z + 2
In a right-hand side of function `q': \ (y : z) -> z + 2
tcfail017.hs:10:
Could not deduce (C [a]) from the context (B a)
arising from the instance declaration at tcfail017.hs:10
Probable fix:
Add (C [a]) to the instance declaration superclass context
Or add an instance declaration for (C [a])
arising from the instance declaration at tcfail017.hs:10
In the instance declaration for `B [a]'
tcfail018.hs:5:
No instance for (Num [a])
arising from the literal `1' at tcfail018.hs:5
arising from the literal `1' at tcfail018.hs:5
Possible cause: the monomorphism restriction applied to the following:
a :: a (bound at tcfail018.hs:5)
In the right-hand side of a pattern binding: 1
In a pattern binding: (a : []) = 1
tcfail019.hs:18:
Could not deduce (C [a], B [a]) from the context ()
arising from the instance declaration at tcfail019.hs:18
Probable fix:
Add (C [a], B [a]) to the instance declaration superclass context
Or add an instance declaration for (C [a], B [a])
arising from the instance declaration at tcfail019.hs:18
In the instance declaration for `D [a]'
tcfail020.hs:10:
Could not deduce (A [a]) from the context (A a)
arising from the instance declaration at tcfail020.hs:10
Probable fix:
Add (A [a]) to the instance declaration superclass context
Or add an instance declaration for (A [a])
arising from the instance declaration at tcfail020.hs:10
In the instance declaration for `B [a]'
tcfail028.hs:4:
Couldn't match `k -> k1' against `Type bx'
Expected kind: k -> k1
Inferred kind: Type bx
When checking that `A a' is a type
Kind error: `A a' is not applied to enough type arguments
In the data type declaration for `A'
tcfail034.hs:17:
Could not deduce (Integral a) from the context (Num a, Eq a)
arising from use of `mod' at tcfail034.hs:17
Probable fix:
Add (Integral a) to the type signature(s) for `test'
arising from use of `mod' at tcfail034.hs:17
In the first argument of `(==)', namely `(x `mod` 3)'
In a right-hand side of function `test': (x `mod` 3) == 0
In the definition of `test': test x = (x `mod` 3) == 0
tcfail040.hs:19:
Ambiguous type variable(s) `a' in the constraint `ORD a'
arising from use of `<<' at tcfail040.hs:19
Ambiguous type variable(s) `a' in the constraint (ORD a)
arising from use of `<<' at tcfail040.hs:19
In the first argument of `(===)', namely `(<<)'
In a right-hand side of function `f': (<<) === (<<)
In the definition of `f': f = (<<) === (<<)
tcfail042.hs:15:
Could not deduce (Num a) from the context (Eq a, Show a)
arising from the instance declaration at tcfail042.hs:15
Probable fix:
Add (Num a) to the instance declaration superclass context
arising from the instance declaration at tcfail042.hs:15
In the instance declaration for `Bar [a]'
tcfail043.hs:38:
Ambiguous type variable(s) `a' in the constraint `Ord_ a'
arising from use of `gt' at tcfail043.hs:38
Ambiguous type variable(s) `a' in the constraint (Ord_ a)
arising from use of `gt' at tcfail043.hs:38
Possible cause: the monomorphism restriction applied to the following:
search :: a -> [a] -> Bool (bound at tcfail043.hs:38)
In the predicate expression: gt (hd bs) a
In the body of a lambda:
if gt (hd bs) a then
False
else
if eq a (hd bs) then True else search a (tl bs)
In a lambda abstraction:
\ a bs
-> if gt (hd bs) a then
False
else
if eq a (hd bs) then True else search a (tl bs)
tcfail057.hs:5:
Class `RealFrac' used as a type
When checking kinds in `RealFrac a'
In the type: forall a. (RealFrac a) -> a -> a
While checking the type signature for `f'
tcfail063.hs:6:
Couldn't match `*' against `* -> *'
Expected kind: *
Inferred kind: * -> *
Kind error: `Num' is not applied to enough type arguments
When checking kinds in `Num'
In the type: forall a. (Num) => Int -> a -> Int
While checking the type signature for `moby'
tcfail067.hs:12:
Could not deduce (Ord a) from the context ()
arising from the pattern `SubRange (lower, upper) value' at tcfail067.hs:12
Probable fix:
Add (Ord a) to the type signature(s) for `subRangeValue'
arising from the pattern `SubRange (lower, upper) value' at tcfail067.hs:12
When checking the pattern: SubRange (lower, upper) value
In the definition of `subRangeValue':
subRangeValue (SubRange (lower, upper) value) = value
tcfail067.hs:15:
Could not deduce (Ord a) from the context ()
arising from the pattern `SubRange r value' at tcfail067.hs:15
Probable fix:
Add (Ord a) to the type signature(s) for `subRange'
arising from the pattern `SubRange r value' at tcfail067.hs:15
When checking the pattern: SubRange r value
In the definition of `subRange': subRange (SubRange r value) = r
tcfail067.hs:47:
Could not deduce (Ord a) from the context (Show a)
arising from the pattern `SubRange (lower, upper) value' at tcfail067.hs:47
Probable fix:
Add (Ord a) to the type signature(s) for `showRange'
arising from the pattern `SubRange (lower, upper) value' at tcfail067.hs:47
When checking the pattern: SubRange (lower, upper) value
In the definition of `showRange':
showRange (SubRange (lower, upper) value)
......@@ -28,11 +28,11 @@ tcfail067.hs:47:
tcfail067.hs:60:
Could not deduce (Show (SubRange a)) from the context (Num a)
arising from the instance declaration at tcfail067.hs:60
Probable fix:
Add (Show (SubRange a))
to the instance declaration superclass context
Or add an instance declaration for (Show (SubRange a))
arising from the instance declaration at tcfail067.hs:60
In the instance declaration for `Num (SubRange a)'
tcfail067.hs:61:
......@@ -41,11 +41,12 @@ tcfail067.hs:61:
Num a,
Eq (SubRange a),
Show (SubRange a))
arising from use of `numSubRangeNegate' at tcfail067.hs:61
Probable fix:
Add (Ord a) to the class or instance method `negate'
arising from use of `numSubRangeNegate' at tcfail067.hs:61
In a right-hand side of function `negate': numSubRangeNegate
In the definition of `negate': negate = numSubRangeNegate
In the definition for method `negate'
tcfail067.hs:65:
Could not deduce (Ord a)
......@@ -53,20 +54,21 @@ tcfail067.hs:65:
Num a,
Eq (SubRange a),
Show (SubRange a))
arising from use of `SubRange' at tcfail067.hs:65
Probable fix:
Add (Ord a) to the class or instance method `fromInteger'
arising from use of `SubRange' at tcfail067.hs:65
In a right-hand side of function `fromInteger':
SubRange (fromInteger a, fromInteger a) (fromInteger a)
In the definition of `fromInteger':
fromInteger a = SubRange (fromInteger a, fromInteger a)
(fromInteger a)
In the definition for method `fromInteger'
tcfail067.hs:74:
Could not deduce (Ord a) from the context (Num a)
arising from use of `SubRange' at tcfail067.hs:74
Probable fix:
Add (Ord a) to the type signature(s) for `numSubRangeBinOp'
arising from use of `SubRange' at tcfail067.hs:74
In a right-hand side of function `numSubRangeBinOp':
SubRange (result, result) result
In the definition of `numSubRangeBinOp':
......
tcfail070.hs:15:
Couldn't match `*' against `* -> k'
Expected kind: *
Inferred kind: * -> k
Kind error: `[Int]' is applied to too many type arguments
When checking kinds in `[Int] Bool'
In the type synonym declaration for `State'
tcfail072.hs:23:
Ambiguous type variable(s) `p' in the constraint `Ord p'
arising from use of `g' at tcfail072.hs:23
Ambiguous type variable(s) `p' in the constraint (Ord p)
arising from use of `g' at tcfail072.hs:23
In a right-hand side of function `g': g A
In the definition of `g': g (B _ _) = g A
tcfail072.hs:23:
Ambiguous type variable(s) `q' in the constraint `Ord q'
arising from use of `g' at tcfail072.hs:23
Ambiguous type variable(s) `q' in the constraint (Ord q)
arising from use of `g' at tcfail072.hs:23
In a right-hand side of function `g': g A
In the definition of `g': g (B _ _) = g A
tcfail079.hs:9:
Couldn't match `*' against `#'
Expected kind: *
Inferred kind: #
When checking that `Int#' is a type
Kind error: Expecting a lifted type, but `Int#' is unlifted
In the newtype declaration for `Unboxed'
Markdown is supported
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