| 90 | |
| 91 | namespace NCompactTrie { |
| 92 | static inline ui64 ArcSaveOffset(size_t offset, IOutputStream& os) { |
| 93 | using namespace NCompactTrie; |
| 94 | |
| 95 | if (!offset) |
| 96 | return 0; |
| 97 | |
| 98 | char buf[16]; |
| 99 | size_t len = PackOffset(buf, offset); |
| 100 | os.Write(buf, len); |
| 101 | return len; |
| 102 | } |
| 103 | |
| 104 | // Unpack the offset to the next node. The encoding scheme can store offsets |
| 105 | // up to 7 bytes; whether they fit into size_t is another issue. |
no test coverage detected