Indicate endianness (6.d, 2018.12 and later)
enum Endian <NativeEndian LittleEndian BigEndian>;
An enum for indicating endianness, specifically with methods on blob8 and buf8. Consists of NativeEndian, LittleEndian and BigEndian.
multi method Numeric(Endian:D --> Int:D)
Returns the value part of the enum pair.
say NativeEndian.Numeric; # OUTPUT: «0»
say LittleEndian.Numeric; # OUTPUT: «1»
say BigEndian.Numeric; # OUTPUT: «2»
Note that the actual numeric values are subject to change. So please use the named values instead.