def decode.limit

bend-kit-protobuf@0.2.0.0 · protobuf.bend:279

import bend-kit-protobuf@0.2.0.0/protobuf.bend as Protobuf
import Base
import bend-kit-bytes@0.3.3.0/bytes.bend as B

279def decode.limit(ok: Bool, b: B.Bytes, +n: U32, depth: Nat) -> Result<&2, &1, Error, List<&1, Field>>:
280  match ok:
281    case False{}:
282      Fail{Limit{}}
283    case True{}:
284      decode.go(1n+U32.to_nat(n), decode.state(B.Cursor.new(b), depth, Nil{}, Nil{}))

Uses (12)

Used by (1)