Skip to content

Commit 094936e

Browse files
authored
Rollup merge of #141003 - clubby789:ternary-improve, r=compiler-errors
Improve ternary operator recovery This - Improves the span of the error to not point at the next token - Where possible, we use the span of the condition to further improve the span of the error to include the cond, and suggest a maybe-incorrect fix Currently this works on free expressions, not let statements; some more refactoring would be needed to pass the span down, which I'm not sure is worth doing. ### Old ![image](https://github.com/user-attachments/assets/5688cefc-e4ef-4135-a5ba-340ce05ae6f3) ### New ![image](https://github.com/user-attachments/assets/154f5380-e0c8-42c7-9bf8-0adb3d0433fa)
2 parents 2623542 + 33ca0c9 commit 094936e

File tree

0 file changed

+0
-0
lines changed

    0 file changed

    +0
    -0
    lines changed

    0 commit comments

    Comments
     (0)