-
Notifications
You must be signed in to change notification settings - Fork 13.2k
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Logical right and left shift diagnostics. #102067
Conversation
r? @davidtwco (rust-highfive has picked a reviewer for you, use r? to override) |
cc @davidtwco, @compiler-errors, @JohnTitor, @estebank, @TaKO8Ki |
.arithmetic_left_shift_operator_invalid = `<<<` is not a valid left shift operator, consider shifting normally and fixing the sign as needed. | ||
.arithmetic_right_shift_operator_invalid = `>>>` is not a valid right shift operator, consider casting to a signed integer and right shifting normally. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We don't end sentences with period (nor we capitalize the first letter in sentences)
.arithmetic_left_shift_operator_invalid = `<<<` is not a valid left shift operator, consider shifting normally and fixing the sign as needed. | |
.arithmetic_right_shift_operator_invalid = `>>>` is not a valid right shift operator, consider casting to a signed integer and right shifting normally. | |
.arithmetic_left_shift_operator_invalid = `<<<` is not a valid left shift operator, consider shifting normally and fixing the sign as needed | |
.arithmetic_right_shift_operator_invalid = `>>>` is not a valid right shift operator, consider casting to an unsigned integer and right shifting normally |
I would prefer if the consider...
text was instead a note
, separate from the main label
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree with both of these comments.
.arithmetic_left_shift_operator_invalid = `<<<` is not a valid left shift operator, consider shifting normally and fixing the sign as needed. | ||
.arithmetic_right_shift_operator_invalid = `>>>` is not a valid right shift operator, consider casting to a signed integer and right shifting normally. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree with both of these comments.
r? @estebank |
☔ The latest upstream changes (presumably #101846) made this pull request unmergeable. Please resolve the merge conflicts. |
Hi, I've seen you changed some diagnostic structs in your PR. After #103345, the way we refer to fluent messages changed. They are now in a flat namespace with the same identifier as in the fluent file. For example, |
Ah shoot, this slipped under my radar. I'll put finishing this on my calender. |
Switching to waiting on author to incorporate changes. Feel free to request a review with @rustbot author |
@moonheart08 any updates on this? |
Closing this as inactive. Feel free to reöpen this pr or create a new pr if you get the time to work on this. Thanks |
This adds lints for
<<<
and>>>
. They explicitly do not suggest replacements as I could not figure out a simple way to do so for>>>
, and for<<<
the replacement is subjective (it could be<<
, but that doesn't preserve sign.)