A combinator that takes a parser `inner` and produces a parser that also consumes both leading and trailing whitespace, returning the output of `inner`.
(
parser: ParseNext,
)
| 114 | /// A combinator that takes a parser `inner` and produces a parser that also consumes both |
| 115 | /// leading and trailing whitespace, returning the output of `inner`. |
| 116 | pub(crate) fn ws<Input, Output, Error, ParseNext>( |
| 117 | parser: ParseNext, |
| 118 | ) -> impl Parser<Input, Output, Error> |
| 119 | where |
| 120 | Input: StreamIsPartial + Stream<Token: AsChar + Clone>, |
| 121 | ParseNext: Parser<Input, Output, Error>, |
| 122 | Error: ParserError<Input>, |
| 123 | { |
| 124 | trace( |
| 125 | "ws", // |
| 126 | delimited(multispace0, parser, multispace0), |
| 127 | ) |
| 128 | } |
no outgoing calls
no test coverage detected