

Improve diagnostic for missing half of binary operator in `if` condition by Fabi...
source link: https://github.com/rust-lang/rust/pull/91435
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

Fixes #91421. I've also changed it so that it doesn't consume the else
token in the error case, because it will try to consume it again afterwards, leading to this incorrect error message (where the else
reported as missing is actually there):
error: expected one of `.`, `;`, `?`, `else`, or an operator, found `{`
--> src/main.rs:4:12
|
4 | } else { 4 };
| ^ expected one of `.`, `;`, `?`, `else`, or an operator
r? @lcnr
Recommend
-
40
Missing data points can sometimes feel like missing jigsaw pieces (photo: author) For a few months now, we’ve been looking at...
-
17
Missing values can cause problems when modeling classification and regression prediction problems with machine learning algorithms. A common approach is to replace missing values with a calculated statistic, such...
-
10
Copy link Contributor Folyd commente...
-
9
Copy link Contributor FabianWolff commented...
-
3
Contributor ...
-
6
Contributor
-
6
I will share with us some tips that improved my skill in Typescript ! Today we will learn satisfies operator that appear in the 4.9 TS Update ! A "Boring" error Let's go on the common error when using Record w...
-
4
AWS Introduces Global Condition Context Keys to Improve EC2 Security Mar 19, 2023...
-
13
Member Current behavior Currently ockam space [list, delete, show]
-
10
Introducing Swell v1.18: new binary file upload, dark mode improvements, improved TypeScript quality, and increased testing!3 min read17 hours ago
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK