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
omega-mv / seed / omc / om2 / s1 / hex-max.om
| 1 | om2 |
| 2 | note hex literals take the place's type under the decimal range rule |
| 3 | fn main to int |
| 4 | a = ulong 0xffffffffffffffff |
| 5 | if ne a 18446744073709551615 |
| 6 | ret 1 |
| 7 | end |
| 8 | b = uint 0xffffffff |
| 9 | if ne b 4294967295 |
| 10 | ret 2 |
| 11 | end |
| 12 | c = long 0x7fffffffffffffff |
| 13 | if ne c 9223372036854775807 |
| 14 | ret 3 |
| 15 | end |
| 16 | d = uchar 0x0 |
| 17 | if ne d 0 |
| 18 | ret 4 |
| 19 | end |
| 20 | e = ushort 0x00ff |
| 21 | if ne e 255 |
| 22 | ret 5 |
| 23 | end |
| 24 | f = ulong 0xdeadbeef |
| 25 | if ne f 3735928559 |
| 26 | ret 6 |
| 27 | end |
| 28 | ret 0 |
| 29 | end |