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 / s5 / scrub-chain.om
| 1 | note S5 scrub reached through two calls, both compiled before a long global (length 5000 > 4095, so it |
| 2 | note would pin base and length) that main reads after the chain returns. omc 0d7f2f42 pinned it and the |
| 3 | note scrub cleared both pins without restoring them: trap 3, exit 103. Exit 0 is the pass. |
| 4 | om2 |
| 5 | fn deep to ulong |
| 6 | k = scrub 64 |
| 7 | ret ulong k |
| 8 | end |
| 9 | fn mid to ulong |
| 10 | k = deep |
| 11 | ret k |
| 12 | end |
| 13 | global g ulong 5000 |
| 14 | fn main to int |
| 15 | j = ulong 4999 |
| 16 | put g j 11 |
| 17 | k = mid |
| 18 | y = get g j |
| 19 | if ne y 11 |
| 20 | ret 2 |
| 21 | end |
| 22 | ret int k |
| 23 | end |