def write_fixed32
import bend-kit-protobuf@0.2.0.0/protobuf.bend as Protobufimport Base
import bend-kit-bytes@0.3.3.0/bytes.bend as B
355def write_fixed32(v: U32, out: B.Bytes, max_size: U32) -> Result<&2, &1, Error, B.Bytes>:
356 B.Bytes{+n, buf} = out
357 +limit = U32.min(max_size, 2147483647)
358 write_fixed32.limit(U32.is_le(n, limit) && U32.is_le(4, (limit - n : U32)), n, buf, v)