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

Make span_extend_to_prev_str() more robust #91607

Merged
merged 2 commits into from
Feb 12, 2022

Conversation

FabianWolff
Copy link
Contributor

Fixes #91560. The logic in span_extend_to_prev_str() is currently quite brittle and fails if there is extra whitespace or something else in between, and it also should return an Option but doesn't currently.

@rust-highfive
Copy link
Collaborator

r? @jackh726

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

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Dec 6, 2021
@FabianWolff FabianWolff force-pushed the issue-91560-const-span branch from 3f57292 to 76fc64e Compare December 6, 2021 23:51
@apiraino apiraino added the T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. label Dec 9, 2021
compiler/rustc_span/src/source_map.rs Outdated Show resolved Hide resolved
compiler/rustc_resolve/src/diagnostics.rs Outdated Show resolved Hide resolved
@jackh726 jackh726 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-review Status: Awaiting review from the assignee but also interested parties. labels Dec 18, 2021
@FabianWolff FabianWolff force-pushed the issue-91560-const-span branch from 76fc64e to 3f609b7 Compare January 15, 2022 21:22
@FabianWolff
Copy link
Contributor Author

@rustbot ready

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Jan 15, 2022
@FabianWolff FabianWolff requested a review from jackh726 January 15, 2022 21:23
@jackh726
Copy link
Member

@bors r+

@bors
Copy link
Contributor

bors commented Jan 30, 2022

📌 Commit 3f609b7 has been approved by jackh726

@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 Jan 30, 2022
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Jan 30, 2022
… r=jackh726

Make `span_extend_to_prev_str()` more robust

Fixes rust-lang#91560. The logic in `span_extend_to_prev_str()` is currently quite brittle and fails if there is extra whitespace or something else in between, and it also should return an `Option` but doesn't currently.
@matthiaskrgr
Copy link
Member

Failed in a rollup: #93491 (comment)
Looks like test output needs to be updated.
@bors 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 Jan 31, 2022
@FabianWolff FabianWolff force-pushed the issue-91560-const-span branch from 3f609b7 to 71ff16b Compare January 31, 2022 19:44
@FabianWolff
Copy link
Contributor Author

Fixed. The problem was that an only-aarch64 test failed, which doesn't run in the CI or when I run the tests locally. This also means that I couldn't run the (hopefully) fixed version of the test, so please double-check with the output in #93491 (comment) (the relevant changes are in the latest commit). Thanks!

@rustbot ready

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Jan 31, 2022
@jackh726
Copy link
Member

@bors r+

@bors
Copy link
Contributor

bors commented Feb 11, 2022

📌 Commit 71ff16b has been approved by jackh726

@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 Feb 11, 2022
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Feb 11, 2022
… r=jackh726

Make `span_extend_to_prev_str()` more robust

Fixes rust-lang#91560. The logic in `span_extend_to_prev_str()` is currently quite brittle and fails if there is extra whitespace or something else in between, and it also should return an `Option` but doesn't currently.
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Feb 11, 2022
… r=jackh726

Make `span_extend_to_prev_str()` more robust

Fixes rust-lang#91560. The logic in `span_extend_to_prev_str()` is currently quite brittle and fails if there is extra whitespace or something else in between, and it also should return an `Option` but doesn't currently.
bors added a commit to rust-lang-ci/rust that referenced this pull request Feb 11, 2022
…askrgr

Rollup of 10 pull requests

Successful merges:

 - rust-lang#90955 (Rename `FilenameTooLong` to `InvalidFilename` and also use it for Windows' `ERROR_INVALID_NAME`)
 - rust-lang#91607 (Make `span_extend_to_prev_str()` more robust)
 - rust-lang#92895 (Remove some unused functionality)
 - rust-lang#93635 (Add missing platform-specific information on current_dir and set_current_dir)
 - rust-lang#93660 (rustdoc-json: Add some tests for typealias item)
 - rust-lang#93782 (Split `pauth` target feature)
 - rust-lang#93868 (Fix incorrect register conflict detection in asm!)
 - rust-lang#93888 (Implement `AsFd` for `&T` and `&mut T`.)
 - rust-lang#93909 (Fix typo: explicitely -> explicitly)
 - rust-lang#93910 (fix mention of moved function in `rustc_hir` docs)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit b7c48b4 into rust-lang:master Feb 12, 2022
@rustbot rustbot added this to the 1.60.0 milestone Feb 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
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.

"error[E0435]: attempt to use a non-constant value in a constant" shows wrong fix with mut variables
8 participants