macro_rules! first {
($input:expr, $submacro:ident!($($arguments:tt)*)) => { ... };
($input:expr, $f:expr) => { ... };
}
Expand description
first!(I -> Result<I, O>) => I -> Result<I, O>
is applying the skip
rule before the first argument; it allows to skip
tokens.
ยงExamples
use tagua_parser::Result;
named!(
test,
first!(tag!("bar"))
);
assert_eq!(test(&b"/* foo */bar"[..]), Result::Done(&b""[..], &b"bar"[..]));