Function cucumber_expressions::parse::parameter
source ·
[−]pub fn parameter<'a, Input: 'a>(
input: Input
) -> IResult<Input, Parameter<Input>, Error<Input>> where
Input: Clone + Display + Offset + InputLength + InputTake + InputTakeAtPosition<Item = char> + Slice<RangeFrom<usize>> + InputIter + for<'s> Compare<&'s str>,
<Input as InputIter>::Item: AsChar + Copy,
Error<Input>: ParseError<Input>,
for<'s> &'s str: FindToken<<Input as InputIter>::Item>, Expand description
Parses a parameter as defined in the grammar spec.
Grammar
parameter = '{', name*, '}'
name = (- name-to-escape) | ('\', name-to-escape)
name-to-escape = '{' | '}' | '(' | '/' | '\'Example
{}
{name}
{with spaces}
{escaped \/\{\(}
{no need to escape )}
{🦀}Errors
Recoverable Error
- If
inputdoesn’t start with{.