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 / coder / observed / elif_is_assignment.om

14 lines · 321 bytes Raw Blame History
1note probe: `elif COND` is not a keyword. It compiles as an assignment to a new local named elif, and the
2note line after it runs whenever the if arm runs. With x = 1 an elif chain would return 1; this returns 2.
3fn main to int
4x = ulong 1
5r = int 0
6if lt x 2
7r = int 1
8elif lt x 5
9r = int 2
10else
11r = int 3
12end
13ret r
14end