| 45 | // and writes them to a stream as little endian |
| 46 | |
| 47 | void encode(std::ostream& stream, std::int16_t value) |
| 48 | { |
| 49 | const std::array bytes = {static_cast<char>(value & 0xFF), static_cast<char>(value >> 8)}; |
| 50 | stream.write(bytes.data(), bytes.size()); |
| 51 | } |
| 52 | |
| 53 | void encode(std::ostream& stream, std::uint16_t value) |
| 54 | { |
no test coverage detected