aboutsummaryrefslogtreecommitdiff
path: root/test/cases/compile_errors/indexing_single-item_pointer.zig
blob: b57fccd482546cb771c3a1414f81f48e6a1fd9ba (plain)
1
2
3
4
5
6
7
8
export fn entry(ptr: *i32) i32 {
    return ptr[1];
}

// error
//
// :2:15: error: type '*i32' does not support indexing
// :2:15: note: operand must be an array, slice, tuple, or vector