def parse.header.magic.one

mylsm-lsm-store@0.6.0.1 · src/SstFile.bend:1625

import mylsm-lsm-store@0.6.0.1/src/SstFile.bend as SstFile
import Base
import bend-kit-bytes@0.3.2.0/bytes.bend as Bytes

1625def parse.header.magic.one(
1626  pair: Bytes.Cursor & Maybe<&2, U32>
1627) -> Bytes.Cursor & Result<&1, &1, Error, SstHeader>:
1628  match pair:
1629    case (cursor, Some{1297697875}):
1630      parse.header.magic.two(Bytes.Cursor.u32be(cursor))
1631    case (cursor, _):
1632      (cursor, Fail{Malformed{}})

Uses (13)

Used by (2)