@@ -8,49 +8,49 @@ func test_constantFoldAnd1() -> Int {
8
8
return 42
9
9
}
10
10
// FIXME: this is a false positive.
11
- } // expected-error {{missing return in function expected to return 'Int'}}
11
+ } // expected-error {{missing return in global function expected to return 'Int'}}
12
12
13
13
func test_constantFoldAnd2( ) -> Int {
14
14
while true && false {
15
15
return 42
16
16
}
17
- } // expected-error {{missing return in function expected to return 'Int'}}
17
+ } // expected-error {{missing return in global function expected to return 'Int'}}
18
18
19
19
func test_constantFoldAnd3( ) -> Int {
20
20
while false && true {
21
21
return 42
22
22
}
23
- } // expected-error {{missing return in function expected to return 'Int'}}
23
+ } // expected-error {{missing return in global function expected to return 'Int'}}
24
24
25
25
func test_constantFoldAnd4( ) -> Int {
26
26
while false && false {
27
27
return 42
28
28
}
29
- } // expected-error {{missing return in function expected to return 'Int'}}
29
+ } // expected-error {{missing return in global function expected to return 'Int'}}
30
30
31
31
func test_constantFoldOr1( ) -> Int {
32
32
while true || true {
33
33
return 42
34
34
}
35
35
// FIXME: this is a false positive.
36
- } // expected-error {{missing return in function expected to return 'Int'}}
36
+ } // expected-error {{missing return in global function expected to return 'Int'}}
37
37
38
38
func test_constantFoldOr2( ) -> Int {
39
39
while true || false {
40
40
return 42
41
41
}
42
42
// FIXME: this is a false positive.
43
- } // expected-error {{missing return in function expected to return 'Int'}}
43
+ } // expected-error {{missing return in global function expected to return 'Int'}}
44
44
45
45
func test_constantFoldOr3( ) -> Int {
46
46
while false || true {
47
47
return 42
48
48
}
49
49
// FIXME: this is a false positive.
50
- } // expected-error {{missing return in function expected to return 'Int'}}
50
+ } // expected-error {{missing return in global function expected to return 'Int'}}
51
51
52
52
func test_constantFoldOr4( ) -> Int {
53
53
while false || false {
54
54
return 42
55
55
}
56
- } // expected-error {{missing return in function expected to return 'Int'}}
56
+ } // expected-error {{missing return in global function expected to return 'Int'}}
0 commit comments