try_pattern_match

Function try_pattern_match 

Source
pub fn try_pattern_match(
    pattern: &Pattern,
    value: &Value,
    eval_literal: &dyn Fn(&Literal) -> Value,
) -> Result<Option<Vec<(String, Value)>>, InterpreterError>
Expand description

Try to match a pattern against a value, returning bindings if successful

ยงComplexity

Cyclomatic complexity: 10 (at Toyota Way limit - added Some/None support)