pub trait SpecParser {
type PVal;
// Required method
spec fn spec_parse(&self, ibuf: Seq<u8>) -> Option<(int, Self::PVal)>;
}Expand description
Parser specification.
Required Associated Types§
Required Methods§
Sourcespec fn spec_parse(&self, ibuf: Seq<u8>) -> Option<(int, Self::PVal)>
spec fn spec_parse(&self, ibuf: Seq<u8>) -> Option<(int, Self::PVal)>
Attempts to parse a value from ibuf.
Returns Some((n, v)) on success, where n bytes were consumed and v is
the parsed value, or None on failure.