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 / ir / x-remmin.om

12 lines · 236 bytes Raw Blame History
1note x-remmin: signed minimum rem -1 is 0 and does not trap (exit 5 when the remainder is 0, else 6)
2fn f a long b long to long
3ret rem a b
4end
5fn main to int
6m = sub long -9223372036854775807 1
7r = f m -1
8if eq r 0
9ret 5
10end
11ret 6
12end