use nom::bytes::complete::tag; fn main() { let input = "this is my test input".to_owned(); let output = tag::<_, _, (_, nom::error::ErrorKind)>("this")(input.as_str()).unwrap(); println!("{:#?}", output); } struct WrappedInput<'s> { contents: &'s str, }