interplane.Get Omega
Read in your language

omega-mv

Omega: a language for verified programs, semantic identity and machine realization. Seed-born work and existing implementations have distinct provenance.

Brought by drakestapleton

branch main Branches Tags History

omega-mv / si / harness / examples / mistake_short_circuit.om

10 lines · 261 bytes Raw Blame History
1note mistake_short_circuit: and/or evaluate both sides, so this still loads a[4] and traps 3 (exit 103)
2note fix: test the bound in an outer if, then load inside it
3fn main to int
4a = new uchar 4 0
5i = ulong 4
6if and lt i len a eq get a i 0
7ret 1
8end
9ret 0
10end