def parse.footer.check
mylsm-lsm-store@0.6.0.1 · src/SstFile.bend:1037
import mylsm-lsm-store@0.6.0.1/src/SstFile.bend as SstFile
import Base
import mylsm-lsm-store@0.6.0.1/src/MemTable.bend as MemTable
import mylsm-lsm-store@0.6.0.1/src/Sstable.bend as Sstable
import bend-kit-bytes@0.3.2.0/bytes.bend as Bytes
1037def parse.footer.check(
1038 +level: U32,
1039 entries: List<&2, MemTable.Entry>,
1040 at_end: Bool,
1041 comparison: Bytes.Bytes & Bytes.Bytes & Bool
1042) -> Result<&1, &1, Error, Sstable.Table>:
1043 match comparison:
1044 case (claimed_back, expected_back, False{}):
1045 Fail{ChecksumMismatch{}}
1046 case (claimed_back, expected_back, True{}):
1047 parse.footer.end(level, entries, at_end)