diff options
Diffstat (limited to 'src/streamblock.nim')
-rw-r--r-- | src/streamblock.nim | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/streamblock.nim b/src/streamblock.nim index 49c3dcd..403687e 100644 --- a/src/streamblock.nim +++ b/src/streamblock.nim | |||
@@ -34,6 +34,9 @@ type StreamBlock* = object | |||
34 | else: | 34 | else: |
35 | discard | 35 | discard |
36 | 36 | ||
37 | proc isLast*(streamBlock: StreamBlock): bool = | ||
38 | streamBlock.last | ||
39 | |||
37 | proc readSerialised*(bitReader: BitReader): StreamBlock = | 40 | proc readSerialised*(bitReader: BitReader): StreamBlock = |
38 | result.last = bitReader.readBool() | 41 | result.last = bitReader.readBool() |
39 | result.kind = bitReader.readBits(2, uint8).BlockKind | 42 | result.kind = bitReader.readBits(2, uint8).BlockKind |