summaryrefslogtreecommitdiff
path: root/testsuite/tests/typecheck/should_fail/T12918b.stderr
blob: bb53f774b5fbbdc1f1500c5b442c6f3044f47d32 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41

T12918b.hs:8:11: error:
    • The default type signature for bar1: forall b. b -> a
      does not match its corresponding non-default type signature
    • When checking the class method:
        bar1 :: forall a b. Foo1 a => a -> b
      In the class declaration for ‘Foo1’

T12918b.hs:12:11: error:
    • The default type signature for bar2: forall x. x
      does not match its corresponding non-default type signature
    • When checking the class method:
        bar2 :: forall a b. Foo1 a => a -> b
      In the class declaration for ‘Foo1’

T12918b.hs:12:11: error:
    • Could not deduce ‘Foo1 a0’
      from the context: Foo1 a
        bound by the type signature for:
                   bar2 :: forall a x. Foo1 a => x
        at T12918b.hs:12:11-14
      The type variable ‘a0’ is ambiguous
    • In the ambiguity check for ‘bar2’
      To defer the ambiguity check to use sites, enable AllowAmbiguousTypes
      When checking the class method:
        bar2 :: forall a b. Foo1 a => a -> b
      In the class declaration for ‘Foo1’

T12918b.hs:16:11: error:
    • The default type signature for bar3: a -> Int
      does not match its corresponding non-default type signature
    • When checking the class method:
        bar3 :: forall a b. Foo1 a => a -> b
      In the class declaration for ‘Foo1’

T12918b.hs:20:11: error:
    • The default type signature for bar4: forall b. a -> b
      does not match its corresponding non-default type signature
    • When checking the class method:
        bar4 :: forall a. Foo1 a => a -> Int
      In the class declaration for ‘Foo1’