| 77 | |
| 78 | template <typename T> |
| 79 | constexpr T DecodeFixed(const char *ptr) { |
| 80 | T value = 0; |
| 81 | |
| 82 | __builtin_memcpy(&value, ptr, sizeof(value)); |
| 83 | |
| 84 | return IsLittleEndian() ? BitSwap(value) : value; |
| 85 | } |
| 86 | |
| 87 | inline uint8_t DecodeFixed8(const char *ptr) { return DecodeFixed<uint8_t>(ptr); } |
| 88 | inline uint16_t DecodeFixed16(const char *ptr) { return DecodeFixed<uint16_t>(ptr); } |
nothing calls this directly
no test coverage detected