| 1 | vlib/v/checker/tests/generic_mut_struct_index_err.vv:7:3: error: type `mut Heap[int]` does not support slicing |
| 2 | 5 | |
| 3 | 6 | fn (mut h Heap[T]) insert(mut element T, pos int) { |
| 4 | 7 | h[pos] = element |
| 5 | | ~~~~~ |
| 6 | 8 | } |
| 7 | 9 | |
| 8 | vlib/v/checker/tests/generic_mut_struct_index_err.vv:7:11: error: cannot assign to `h[pos]`: expected `Heap[int]`, not `int` |
| 9 | 5 | |
| 10 | 6 | fn (mut h Heap[T]) insert(mut element T, pos int) { |
| 11 | 7 | h[pos] = element |
| 12 | | ~~~~~~~ |
| 13 | 8 | } |
| 14 | 9 | |
| 15 |