| 1 | vlib/v/checker/tests/cast_to_byte_err.vv:10:7: error: cannot cast type `string` to `u8` |
| 2 | 8 | fn main() { |
| 3 | 9 | // should be errors: |
| 4 | 10 | _ := u8('hello') |
| 5 | | ~~~~~~~~~~~ |
| 6 | 11 | _ := u8(SAlias('hello')) |
| 7 | 12 | |
| 8 | vlib/v/checker/tests/cast_to_byte_err.vv:11:7: error: cannot cast type `SAlias` to `u8` |
| 9 | 9 | // should be errors: |
| 10 | 10 | _ := u8('hello') |
| 11 | 11 | _ := u8(SAlias('hello')) |
| 12 | | ~~~~~~~~~~~~~~~~~~~ |
| 13 | 12 | |
| 14 | 13 | // should be allowed: |
| 15 |