swift
0883b4ba - [Parse] Recover slightly better from bad shorthand `if let`

Commit
2 years ago
[Parse] Recover slightly better from bad shorthand `if let` Instead of assuming that `if let <expr>` is meant to be `if case <expr> = ...`, turn it into `if let _ = <expr>`, which is consistent with the fix-it we suggest. This currently doesn't have much of an effect on the diagnostics we produce, but will be important once we start doing bidirectional inference for ExprPatterns, as it avoids unhelpful diagnostics.
Author
Parents
Loading