vxx2 / vlib / v / checker / tests / pointer_cast_number_outside_unsafe_err.out
32 lines · 32 sloc · 1.17 KB · 6c9b3c8ebf7b7478e66c27ca67dc44b86f7f2f08
Raw
1vlib/v/checker/tests/pointer_cast_number_outside_unsafe_err.vv:6:5: error: cannot null cast a pointer, use &int(unsafe { nil })
2 4 | value := 1
3 5 |
4 6 | _ = &int(0)
5 | ~~~~~~~
6 7 | _ = &int(zero)
7 8 | _ = &int(one)
8vlib/v/checker/tests/pointer_cast_number_outside_unsafe_err.vv:7:5: error: cannot null cast a pointer, use &int(unsafe { nil })
9 5 |
10 6 | _ = &int(0)
11 7 | _ = &int(zero)
12 | ~~~~~~~~~~
13 8 | _ = &int(one)
14 9 | _ = &int(value)
15vlib/v/checker/tests/pointer_cast_number_outside_unsafe_err.vv:8:5: error: cannot cast a number to `&int` outside `unsafe`
16 6 | _ = &int(0)
17 7 | _ = &int(zero)
18 8 | _ = &int(one)
19 | ~~~~~~~~~
20 9 | _ = &int(value)
21 10 | _ = &&int(0)
22vlib/v/checker/tests/pointer_cast_number_outside_unsafe_err.vv:9:5: error: cannot cast a number to `&int` outside `unsafe`
23 7 | _ = &int(zero)
24 8 | _ = &int(one)
25 9 | _ = &int(value)
26 | ~~~~~~~~~~~
27 10 | _ = &&int(0)
28vlib/v/checker/tests/pointer_cast_number_outside_unsafe_err.vv:10:5: error: cannot null cast a pointer, use &&int(unsafe { nil })
29 8 | _ = &int(one)
30 9 | _ = &int(value)
31 10 | _ = &&int(0)
32 | ~~~~~~~~
33