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 / host / tests / psync.om

28 lines · 280 bytes Raw Blame History
1text p "hs.tmp"
2fn main to int
3s = getsid 0
4if le s long 0
5ret 1
6end
7fd = int fopen p 0 len p 578 420
8if lt fd 0
9ret 2
10end
11r = syncfs fd
12if ne r 0
13ret 3
14end
15r = shutdown fd 2
16if ge r 0
17ret 4
18end
19r = fclose fd
20if ne r 0
21ret 5
22end
23r = unlink p 0 len p
24if ne r 0
25ret 6
26end
27ret 0
28end