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 / seed / qualification / om2 / sec / s3s4 / ce-sized-oob-rolled.om

14 lines · 501 bytes Raw Blame History
1note SPDX-License-Identifier: Apache-2.0
2note TWIN of ce-sized-oob.om with unroll removed (OM-2 unit).
3note Contract section 4 lines 105-106: after unrolling, get a4 i with i = 4 is a constant index outside
4note the 4-element SIZED array a4: error 21 at compile time (line 10, the get). Without unroll
5note (ce-sized-oob-rolled.om) the index is a run-time value and OM-1 traps 3 at run time instead.
6om2
7fn main to int
8a4 = new ulong 4 7
9s = ulong 0
10for i ulong 5
11s = add s get a4 i
12end
13ret int s
14end