summaryrefslogtreecommitdiff
path: root/testsuite/tests/ado/ado002.stderr
blob: 3402d0df5514d1e9f7f9be535be831dca70d34d4 (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
70
71
72
73
74
75
76
77
78
79
80
81

ado002.hs:8:8: error:
    • Couldn't match expected type: Char -> IO b0
                  with actual type: IO Char
    • The function ‘getChar’ is applied to one value argument,
        but its type ‘IO Char’ has none
      In a stmt of a 'do' block: y <- getChar 'a'
      In the expression:
        do x <- getChar
           y <- getChar 'a'
           print (x, y)

ado002.hs:9:3: error:
    • Couldn't match type ‘()’ with ‘Int’
      Expected: IO Int
        Actual: IO ()
    • In a stmt of a 'do' block: print (x, y)
      In the expression:
        do x <- getChar
           y <- getChar 'a'
           print (x, y)
      In an equation for ‘f’:
          f = do x <- getChar
                 y <- getChar 'a'
                 print (x, y)

ado002.hs:15:11: error:
    • Couldn't match expected type ‘Int’ with actual type ‘Char’
    • In the expression: y
      In a stmt of a 'do' block: return (y, x)
      In the expression:
        do x <- getChar
           y <- getChar
           return (y, x)

ado002.hs:15:13: error:
    • Couldn't match expected type ‘Int’ with actual type ‘Char’
    • In the expression: x
      In a stmt of a 'do' block: return (y, x)
      In the expression:
        do x <- getChar
           y <- getChar
           return (y, x)

ado002.hs:23:9: error:
    • Couldn't match expected type: Char -> IO a0
                  with actual type: IO Char
    • The function ‘getChar’ is applied to one value argument,
        but its type ‘IO Char’ has none
      In a stmt of a 'do' block: x5 <- getChar x4
      In the expression:
        do x1 <- getChar
           x2 <- getChar
           x3 <- const (return ()) x1
           x4 <- getChar
           x5 <- getChar x4
           return (x2, x4)

ado002.hs:24:11: error:
    • Couldn't match expected type ‘Int’ with actual type ‘Char’
    • In the expression: x2
      In a stmt of a 'do' block: return (x2, x4)
      In the expression:
        do x1 <- getChar
           x2 <- getChar
           x3 <- const (return ()) x1
           x4 <- getChar
           x5 <- getChar x4
           return (x2, x4)

ado002.hs:24:14: error:
    • Couldn't match expected type ‘Int’ with actual type ‘Char’
    • In the expression: x4
      In a stmt of a 'do' block: return (x2, x4)
      In the expression:
        do x1 <- getChar
           x2 <- getChar
           x3 <- const (return ()) x1
           x4 <- getChar
           x5 <- getChar x4
           return (x2, x4)