v/vlib/v/parser/tests/prefix_first.out

29 lines
1.1 KiB
Plaintext

vlib/v/parser/tests/prefix_first.vv:15:3: warning: move infix `-` operator before new line (if infix intended) or use brackets for a prefix expression
13 | _ = if true {
14 | v = 1
15 | -1
| ^
16 | } else {1}
17 | _ = p
vlib/v/parser/tests/prefix_first.vv:27:3: warning: move infix `&` operator before new line (if infix intended) or use brackets for a prefix expression
25 | _ = opt() or {
26 | _ = 1
27 | &v
| ^
28 | }
29 | }
vlib/v/parser/tests/prefix_first.vv:13:6: error: `if` expression requires an expression as the last statement of every branch
11 |
12 | // later this should compile correctly
13 | _ = if true {
| ~~~~~~~
14 | v = 1
15 | -1
vlib/v/parser/tests/prefix_first.vv:25:12: error: last statement in the `or {}` block should be an expression of type `&int` or exit parent scope
23 | // later this should compile correctly
24 | v := 3
25 | _ = opt() or {
| ~~~~
26 | _ = 1
27 | &v