Handle methodcalls & operators in patterns
This commit is contained in:
parent
6351247048
commit
6f014a81b2
29 changed files with 809 additions and 66 deletions
|
@ -772,6 +772,20 @@ parse_unexpected_const_param_declaration = unexpected `const` parameter declarat
|
|||
parse_unexpected_default_value_for_lifetime_in_generic_parameters = unexpected default lifetime parameter
|
||||
.label = lifetime parameters cannot have default values
|
||||
|
||||
parse_unexpected_expr_in_pat =
|
||||
expected {$is_bound ->
|
||||
[true] a pattern range bound
|
||||
*[false] a pattern
|
||||
}, found {$is_method_call ->
|
||||
[true] a method call
|
||||
*[false] an expression
|
||||
}
|
||||
|
||||
.label = {$is_method_call ->
|
||||
[true] method calls
|
||||
*[false] arbitrary expressions
|
||||
} are not allowed in patterns
|
||||
|
||||
parse_unexpected_if_with_if = unexpected `if` in the condition expression
|
||||
.suggestion = remove the `if`
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue