Function parse_value

Source
fn parse_value<'a, O, P: Parser<&'a str, O, ErrMode<ContextError>>>(
    keyword: &Keyword,
    value: &'a Value,
    parser: P,
) -> Result<O, BridgeError>
Expand description

Ensures that a combination of Keyword and Value uses a Value::Single and parses the value as a specific type.

ยงErrors

Returns a error for keyword if value is not Value::Single or cannot be parsed as the specific type.