-
-
Notifications
You must be signed in to change notification settings - Fork 14.5k
Fix error spans for asm!() args that are macros
#152157
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
Merged
Merged
+41
−31
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Collaborator
|
rustbot has assigned @petrochenkov. Use |
Collaborator
|
The job Click to see the possible cause of the failure (guessed by this bot) |
Contributor
|
@bors r+ |
Contributor
JonathanBrouwer
added a commit
to JonathanBrouwer/rust
that referenced
this pull request
Feb 9, 2026
…=petrochenkov Fix error spans for `asm!()` args that are macros Fixes rust-lang#131292 which is exactly the same issue as rust-lang#129503 but for [`err.secondary_label`](https://github.com/rust-lang/rust/blob/9f4b56a5aed81e8c36cc26b3c1b4666ead6b71fc/compiler/rustc_builtin_macros/src/asm.rs#L399-L401) instead of [`err.span`](https://github.com/rust-lang/rust/blob/9f4b56a5aed81e8c36cc26b3c1b4666ead6b71fc/compiler/rustc_builtin_macros/src/asm.rs#L385-L391). The latter issue was fixed in rust-lang#130917 so see that PR for context. In addition to the above, the current PR also proactively fixes potential future issues of the same kind which would have occurred over [here ](https://github.com/rust-lang/rust/blob/9f4b56a5aed81e8c36cc26b3c1b4666ead6b71fc/compiler/rustc_builtin_macros/src/asm.rs#L478-L482)and [here](https://github.com/rust-lang/rust/blob/9f4b56a5aed81e8c36cc26b3c1b4666ead6b71fc/compiler/rustc_builtin_macros/src/asm.rs#L493-L497).
This was referenced Feb 9, 2026
rust-bors bot
pushed a commit
that referenced
this pull request
Feb 10, 2026
…uwer Rollup of 7 pull requests Successful merges: - #151960 (rustc_parse: improve the error diagnostic for "missing let") - #152157 (Fix error spans for `asm!()` args that are macros) - #152317 (fix: sup_trace to sub_trace) - #150897 (rustc_parse_format: improve diagnostics for unsupported debug = syntax) - #151154 (Add `s390x-unknown-none-softfloat` with `RustcAbi::Softfloat`) - #152013 (Update to Xcode 26.2) - #152326 (Remove the compiler adhoc group)
rust-timer
added a commit
that referenced
this pull request
Feb 10, 2026
Rollup merge of #152157 - gurry:131292-asm-concat-unicode, r=petrochenkov Fix error spans for `asm!()` args that are macros Fixes #131292 which is exactly the same issue as #129503 but for [`err.secondary_label`](https://github.com/rust-lang/rust/blob/9f4b56a5aed81e8c36cc26b3c1b4666ead6b71fc/compiler/rustc_builtin_macros/src/asm.rs#L399-L401) instead of [`err.span`](https://github.com/rust-lang/rust/blob/9f4b56a5aed81e8c36cc26b3c1b4666ead6b71fc/compiler/rustc_builtin_macros/src/asm.rs#L385-L391). The latter issue was fixed in #130917 so see that PR for context. In addition to the above, the current PR also proactively fixes potential future issues of the same kind which would have occurred over [here ](https://github.com/rust-lang/rust/blob/9f4b56a5aed81e8c36cc26b3c1b4666ead6b71fc/compiler/rustc_builtin_macros/src/asm.rs#L478-L482)and [here](https://github.com/rust-lang/rust/blob/9f4b56a5aed81e8c36cc26b3c1b4666ead6b71fc/compiler/rustc_builtin_macros/src/asm.rs#L493-L497).
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.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #131292 which is exactly the same issue as #129503 but for
err.secondary_labelinstead oferr.span. The latter issue was fixed in #130917 so see that PR for context.In addition to the above, the current PR also proactively fixes potential future issues of the same kind which would have occurred over here and here.