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 / ng / tests / opt / x-conv.oir

16 lines · 264 bytes Raw Blame History
1omegair 1
2fn @f0 flags 0 %1:u64 -> u8
3block ^0
4%2 = chk.conv u8 5 %0 %1
5%3 = conv u8 0 %1
6retv %2 %3
7end
8export @f1 flags 0 -> i32
9block ^0
10%1 = const u64 255
11%2 %3 = call u8 %0 @f0 %1
12%4 = const u64 256
13%5 %6 = call u8 %2 @f0 %4
14%7 = conv i32 0 %6
15retv %5 %7
16end