| 1 | vlib/v/checker/tests/cast_voidptr_to_struct_err.vv:6:9: error: cannot cast `voidptr` to struct |
| 2 | 4 | |
| 3 | 5 | fn unwrap_concrete(ptr voidptr) Foo { |
| 4 | 6 | return Foo(ptr) |
| 5 | | ~~~~~~~~ |
| 6 | 7 | } |
| 7 | 8 | |
| 8 | vlib/v/checker/tests/cast_voidptr_to_struct_err.vv:10:9: error: cannot cast `voidptr` to struct |
| 9 | 8 | |
| 10 | 9 | fn unwrap_generic[T](ptr voidptr) T { |
| 11 | 10 | return T(ptr) |
| 12 | | ~~~~~~ |
| 13 | 11 | } |
| 14 | 12 | |
| 15 |