summaryrefslogtreecommitdiff
path: root/testsuite/tests/rebindable/rebindable6.stderr
blob: 8d2ea099289af3e001b7c7a88522b785fe1682ca (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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69

rebindable6.hs:110:17: error:
    • Ambiguous type variable ‘t0’ arising from a do statement
      prevents the constraint ‘(HasSeq
                                  (IO a -> t0 -> IO b))’ from being solved.
        (maybe you haven't applied a function to enough arguments?)
      Relevant bindings include
        g :: IO (Maybe b) (bound at rebindable6.hs:108:19)
        f :: IO a (bound at rebindable6.hs:108:17)
        test_do :: IO a -> IO (Maybe b) -> IO b
          (bound at rebindable6.hs:108:9)
      Probable fix: use a type annotation to specify what ‘t0’ should be.
      These potential instance exist:
        instance HasSeq (IO a -> IO b -> IO b)
          -- Defined at rebindable6.hs:56:18
    • In a stmt of a 'do' block: f
      In the expression:
        do { f;
             Just (b :: b) <- g;
             return b }
      In an equation for ‘test_do’:
          test_do f g
            = do { f;
                   Just (b :: b) <- g;
                   return b }

rebindable6.hs:111:17: error:
    • Ambiguous type variable ‘t1’ arising from a do statement
                                   with the failable pattern ‘Just (b :: b)’
      prevents the constraint ‘(HasFail
                                  ([Prelude.Char] -> t1))’ from being solved.
        (maybe you haven't applied a function to enough arguments?)
      Probable fix: use a type annotation to specify what ‘t1’ should be.
      These potential instance exist:
        instance HasFail (String -> IO a)
          -- Defined at rebindable6.hs:61:18
    • In a stmt of a 'do' block: Just (b :: b) <- g
      In the expression:
        do { f;
             Just (b :: b) <- g;
             return b }
      In an equation for ‘test_do’:
          test_do f g
            = do { f;
                   Just (b :: b) <- g;
                   return b }

rebindable6.hs:112:17: error:
    • Ambiguous type variable ‘t1’ arising from a use of ‘return’
      prevents the constraint ‘(HasReturn (b -> t1))’ from being solved.
        (maybe you haven't applied a function to enough arguments?)
      Relevant bindings include
        b :: b (bound at rebindable6.hs:111:23)
        g :: IO (Maybe b) (bound at rebindable6.hs:108:19)
        test_do :: IO a -> IO (Maybe b) -> IO b
          (bound at rebindable6.hs:108:9)
      Probable fix: use a type annotation to specify what ‘t1’ should be.
      These potential instance exist:
        instance HasReturn (a -> IO a) -- Defined at rebindable6.hs:46:18
    • In a stmt of a 'do' block: return b
      In the expression:
        do { f;
             Just (b :: b) <- g;
             return b }
      In an equation for ‘test_do’:
          test_do f g
            = do { f;
                   Just (b :: b) <- g;
                   return b }