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 / tools / exp445 / arms / examples / rotl8 / program.osc
| 1 | fn rotl8(x: u8, k: u8) -> u8 { |
| 2 | let s: u8 = k % 8; |
| 3 | if s == 0 { return x; } |
| 4 | return (x << s) | (x >> (8 - s)); |
| 5 | } |