Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix the wording of help msg for bitwise not #101846

Merged
merged 3 commits into from
Sep 21, 2022
Merged

Conversation

chenyukang
Copy link
Member

Fixes #101793

@rustbot rustbot added A-translation Area: Translation infrastructure, and migrating existing diagnostics to SessionDiagnostic T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Sep 15, 2022
@rust-highfive
Copy link
Collaborator

r? @davidtwco

(rust-highfive has picked a reviewer for you, use r? to override)

@rustbot
Copy link
Collaborator

rustbot commented Sep 15, 2022

rustc_error_messages was changed

cc @davidtwco, @compiler-errors, @JohnTitor, @estebank, @TaKO8Ki

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Sep 15, 2022
@estebank
Copy link
Contributor

r? @estebank
@bors r+

@bors
Copy link
Contributor

bors commented Sep 15, 2022

📌 Commit 2194fc9 has been approved by estebank

It is now in the queue for this repository.

@rust-highfive rust-highfive assigned estebank and unassigned davidtwco Sep 15, 2022
@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Sep 15, 2022
@estebank
Copy link
Contributor

@bors r-

(CI hasn't yet returned green, if tests passes, I'l r+)

@bors bors added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Sep 15, 2022
@Rageking8
Copy link
Contributor

Rageking8 commented Sep 15, 2022

Ehm shouldn't the phrase "bitwise not" only be used for integer types and the phrase "logical negation" be used for expressions that evaluate to a Boolean?

@chenyukang
Copy link
Member Author

Ehm shouldn't the phrasing "bitwise not" only be used for integer types and the phrasing "logical negation" be used for expressions that evaluate to a Boolean?

You are right, let me tuning it more.

@chenyukang
Copy link
Member Author

For not expr ...,
at the point of parsing, we can not know what the real type of expr untile type checking.

so, maybe the proper message is:
use ! to perform logical negation or bitwise not ?

We can try to testing whether next token is a number, but in other scenario, we can not get it accurate for boolean and number.

@estebank
Copy link
Contributor

r? @compiler-errors :)

@davidtwco
Copy link
Member

@bors r+

@bors
Copy link
Contributor

bors commented Sep 21, 2022

📌 Commit 484b612 has been approved by davidtwco

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Sep 21, 2022
@bors
Copy link
Contributor

bors commented Sep 21, 2022

⌛ Testing commit 484b612 with merge b79b7d8...

@bors
Copy link
Contributor

bors commented Sep 21, 2022

☀️ Test successful - checks-actions
Approved by: davidtwco
Pushing b79b7d8 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Sep 21, 2022
@bors bors merged commit b79b7d8 into rust-lang:master Sep 21, 2022
@rustbot rustbot added this to the 1.66.0 milestone Sep 21, 2022
@rust-timer
Copy link
Collaborator

Finished benchmarking commit (b79b7d8): comparison URL.

Overall result: ❌ regressions - no action needed

@rustbot label: -perf-regression

Instruction count

This is a highly reliable metric that was used to determine the overall result at the top of this comment.

mean1 range count2
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
0.5% [0.5%, 0.5%] 1
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) - - 0

Max RSS (memory usage)

Results

This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.

mean1 range count2
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-1.6% [-1.6%, -1.6%] 1
All ❌✅ (primary) - - 0

Cycles

Results

This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.

mean1 range count2
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-3.1% [-4.1%, -2.2%] 2
All ❌✅ (primary) - - 0

Footnotes

  1. the arithmetic mean of the percent change 2 3

  2. number of relevant changes 2 3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-translation Area: Translation infrastructure, and migrating existing diagnostics to SessionDiagnostic merged-by-bors This PR was explicitly merged by bors. S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Slight refinement to wording of help suggestion as a result of not being used
9 participants