vxx2 / vlib / v / checker / tests / if_expr_last_stmt.out
27 lines · 27 sloc · 928 bytes · 9760a9c6b258017ed728d323cbcd3f7016c40c3b
Raw
1vlib/v/checker/tests/if_expr_last_stmt.vv:2:9: notice: condition is always true
2 1 | fn main() {
3 2 | _ = if true {
4 | ~~~~
5 3 | 1
6 4 | } else if false {
7vlib/v/checker/tests/if_expr_last_stmt.vv:4:12: notice: condition is always false
8 2 | _ = if true {
9 3 | 1
10 4 | } else if false {
11 | ~~~~~
12 5 | } else {
13 6 | }
14vlib/v/checker/tests/if_expr_last_stmt.vv:4:4: error: `if` expression requires an expression as the last statement of every branch
15 2 | _ = if true {
16 3 | 1
17 4 | } else if false {
18 | ~~~~~~~~~~~~~
19 5 | } else {
20 6 | }
21vlib/v/checker/tests/if_expr_last_stmt.vv:5:4: error: `if` expression requires an expression as the last statement of every branch
22 3 | 1
23 4 | } else if false {
24 5 | } else {
25 | ~~~~
26 6 | }
27 7 | }
28