1
1
error: missing `return` statement
2
- --> $DIR/implicit_return.rs:12 :5
2
+ --> $DIR/implicit_return.rs:13 :5
3
3
|
4
4
LL | true
5
5
| ^^^^ help: add `return` as shown: `return true`
6
6
|
7
7
= note: `-D clippy::implicit-return` implied by `-D warnings`
8
8
9
9
error: missing `return` statement
10
- --> $DIR/implicit_return.rs:16 :15
10
+ --> $DIR/implicit_return.rs:17 :15
11
11
|
12
12
LL | if true { true } else { false }
13
13
| ^^^^ help: add `return` as shown: `return true`
14
14
15
15
error: missing `return` statement
16
- --> $DIR/implicit_return.rs:16 :29
16
+ --> $DIR/implicit_return.rs:17 :29
17
17
|
18
18
LL | if true { true } else { false }
19
19
| ^^^^^ help: add `return` as shown: `return false`
20
20
21
21
error: missing `return` statement
22
- --> $DIR/implicit_return.rs:22 :17
22
+ --> $DIR/implicit_return.rs:23 :17
23
23
|
24
24
LL | true => false,
25
25
| ^^^^^ help: add `return` as shown: `return false`
26
26
27
27
error: missing `return` statement
28
- --> $DIR/implicit_return.rs:23 :20
28
+ --> $DIR/implicit_return.rs:24 :20
29
29
|
30
30
LL | false => { true },
31
31
| ^^^^ help: add `return` as shown: `return true`
32
32
33
33
error: missing `return` statement
34
- --> $DIR/implicit_return.rs:36 :9
34
+ --> $DIR/implicit_return.rs:37 :9
35
35
|
36
36
LL | break true;
37
37
| ^^^^^^^^^^ help: change `break` to `return` as shown: `return true`
38
38
39
39
error: missing `return` statement
40
- --> $DIR/implicit_return.rs:43 :13
40
+ --> $DIR/implicit_return.rs:44 :13
41
41
|
42
42
LL | break true;
43
43
| ^^^^^^^^^^ help: change `break` to `return` as shown: `return true`
44
44
45
45
error: missing `return` statement
46
- --> $DIR/implicit_return.rs:51 :13
46
+ --> $DIR/implicit_return.rs:52 :13
47
47
|
48
48
LL | break true;
49
49
| ^^^^^^^^^^ help: change `break` to `return` as shown: `return true`
50
50
51
51
error: missing `return` statement
52
- --> $DIR/implicit_return.rs:69 :18
52
+ --> $DIR/implicit_return.rs:70 :18
53
53
|
54
54
LL | let _ = || { true };
55
55
| ^^^^ help: add `return` as shown: `return true`
56
56
57
57
error: missing `return` statement
58
- --> $DIR/implicit_return.rs:70 :16
58
+ --> $DIR/implicit_return.rs:71 :16
59
59
|
60
60
LL | let _ = || true;
61
61
| ^^^^ help: add `return` as shown: `return true`
62
62
63
63
error: missing `return` statement
64
- --> $DIR/implicit_return.rs:78 :5
64
+ --> $DIR/implicit_return.rs:79 :5
65
65
|
66
66
LL | format!("test {}", "test")
67
67
| ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add `return` as shown: `return format!("test {}", "test")`
68
68
69
69
error: missing `return` statement
70
- --> $DIR/implicit_return.rs:87 :5
70
+ --> $DIR/implicit_return.rs:88 :5
71
71
|
72
72
LL | m!(true, false)
73
73
| ^^^^^^^^^^^^^^^ help: add `return` as shown: `return m!(true, false)`
74
74
75
75
error: missing `return` statement
76
- --> $DIR/implicit_return.rs:93 :13
76
+ --> $DIR/implicit_return.rs:94 :13
77
77
|
78
78
LL | break true;
79
79
| ^^^^^^^^^^ help: change `break` to `return` as shown: `return true`
80
80
81
81
error: missing `return` statement
82
- --> $DIR/implicit_return.rs:98 :17
82
+ --> $DIR/implicit_return.rs:99 :17
83
83
|
84
84
LL | break 'outer false;
85
85
| ^^^^^^^^^^^^^^^^^^ help: change `break` to `return` as shown: `return false`
86
86
87
87
error: missing `return` statement
88
- --> $DIR/implicit_return.rs:113 :5
88
+ --> $DIR/implicit_return.rs:114 :5
89
89
|
90
90
LL | / loop {
91
91
LL | | m!(true);
@@ -99,5 +99,11 @@ LL | m!(true);
99
99
LL | }
100
100
|
101
101
102
- error: aborting due to 15 previous errors
102
+ error: missing `return` statement
103
+ --> $DIR/implicit_return.rs:128:5
104
+ |
105
+ LL | true
106
+ | ^^^^ help: add `return` as shown: `return true`
107
+
108
+ error: aborting due to 16 previous errors
103
109
0 commit comments