Function scan_rules::scanner::exact_width
[−]
[src]
pub fn exact_width<Then>(width: usize, then: Then) -> ExactWidth<Then>
Creates a runtime scanner that forces exactly width
bytes to be consumed.
This is done in two steps: first, it truncates the input provided to the inner scanner to exactly width
bytes. Secondly, it verifies that the inner scanner consumed all of the truncated input.
See: exact_width_a
.