def decode.checksum
import mylsm-lsm-store@0.6.0.1/src/ByteManifest.bend as ByteManifestimport Base
import bend-kit-bytes@0.3.2.0/bytes.bend as Bytes
217# Checks exact size and the SHA-256 checksum over the canonical body.
218def decode.checksum(
219 input: Bytes.Bytes,
220 value: ManifestValue,
221 +offset: U32,
222 +expected_size: U32
223) -> Result<&1, &1, Error, ManifestValue>:
224 decode.checksum.measured(value, offset, expected_size, Bytes.length(input))