titzer / virgil

A fast and lightweight native programming language
1.24k stars 48 forks source link

Simplified for loop #75

Closed octoxalis closed 2 years ago

octoxalis commented 2 years ago

This kind of for loop (/lib/util/Arrays.v3) is not documented in the tutorial:

for (i < index) n[i] = array[i];

What about initialization and incrementation of i variable?

titzer commented 2 years ago

You're right, it wasn't documented. I added documentation in the tutorial. Thanks for pointing this out!