leo/tests/compiler/array/array_range_access_fail.leo

12 lines
190 B
Plaintext
Raw Normal View History

2021-07-19 21:33:18 +03:00
/*
namespace: Compile
expectation: Fail
input_file: input/array_range_access_fail.in
*/
function main (
const x: u32
) {
const y = [1u8; 3];
const z: [u8; 2] = y[..1u32][..x];
}