Function tag
fn tag<T, I, Error: ParseError<I>>(tag: T) -> impl Fn(I) -> crate::internal::IResult<I, I, Error>
where
I: Input + Compare<T>,
T: Input + Clone
Recognizes a pattern
The input data will be compared to the tag combinator's argument and will return the part of the input that matches the argument
It will return Err(Err::Error((_, ErrorKind::Tag))) if the input doesn't match the pattern
Example
# use ;
use tag;
assert_eq!;
assert_eq!;
assert_eq!;