MCPcopy Create free account
hub / github.com/LemonOSProject/LemonOS / BigEndianUInt16

Class BigEndianUInt16

Kernel/include/endian.h:25–47  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

23}
24
25typedef struct BigEndianUInt16 {
26 union{
27 uint16_t value;
28 struct {
29 uint8_t high, low;
30 };
31 };
32
33 BigEndianUInt16() {}
34
35 BigEndianUInt16(const uint16_t val) {
36 value = EndianLittleToBig16(val);
37 }
38
39 BigEndianUInt16& operator=(const uint16_t newValue){
40 value = EndianLittleToBig16(newValue);
41 return *this;
42 }
43
44 operator uint16_t(){
45 return EndianBigToLittle16(value);
46 }
47} __attribute__((packed)) bige_uint16_t;
48
49typedef struct BigEndianUInt32 {
50 union{

Callers

nothing calls this directly

Calls 2

EndianLittleToBig16Function · 0.70
EndianBigToLittle16Function · 0.70

Tested by

no test coverage detected