| 53 | } |
| 54 | |
| 55 | int ReadVarInt32(IInputStream* input, i32* value) { |
| 56 | ui64 varInt; |
| 57 | int bytesRead = ReadVarUInt64(input, &varInt); |
| 58 | if (varInt > Max<ui32>()) { |
| 59 | ythrow yexception() << "The data is too long to read i32"; |
| 60 | } |
| 61 | *value = ZigZagDecode32(static_cast<ui32>(varInt)); |
| 62 | return bytesRead; |
| 63 | } |
| 64 | |
| 65 | int ReadVarInt64(IInputStream* input, i64* value) { |
| 66 | ui64 varInt; |
nothing calls this directly
no test coverage detected