Defs.pack4: def of lawful-words@0.1.0.0 Import: import lawful-words@0.1.0.0/defs.bend as Defs Lines 30-33 of lawful-words@0.1.0.0/defs.bend: https://jend.leeeet.dev/read.txt?path=lawful-words@0.1.0.0/defs.bend&start_line=30&end_line=33 import Base # The word whose bytes 0 to 3 are b0 to b3: b0 | b1 << 8 | b2 << 16 | b3 << 24. # Meant for bytes below 256: larger values spill into the next byte. def pack4(b0: U32, b1: U32, b2: U32, b3: U32) -> U32: U32.or(b0, U32.or(U32.shln(b1, 8n), U32.or(U32.shln(b2, 16n), U32.shln(b3, 24n)))) Uses (3): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.or https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.shln