1
0
Fork 0
mirror of synced 2025-09-23 12:18:44 +00:00
ZoKrates/zokrates_cli/examples/empty_spread_propagation.zok
2022-04-06 20:23:58 +02:00

17 lines
No EOL
292 B
Text

def func<N>() -> bool {
for u32 i in 0..N {}
u64[N] y = [...[0; N-1], 1]; // the rhs should *not* be reduced to [1] because the spread is not empty
u64 q = 0;
for u32 i in 0..N {
q = y[i]
}
return true;
}
def main() {
assert(func::<2>());
return;
}