Skip to content

Make rustc_attr_parsing::SharedContext::emit_lint take a MultiSpan instead of a Span#155097

Merged
rust-bors[bot] merged 1 commit intorust-lang:mainfrom
GuillaumeGomez:emit_lint-multispan
Apr 10, 2026
Merged

Make rustc_attr_parsing::SharedContext::emit_lint take a MultiSpan instead of a Span#155097
rust-bors[bot] merged 1 commit intorust-lang:mainfrom
GuillaumeGomez:emit_lint-multispan

Conversation

@GuillaumeGomez
Copy link
Copy Markdown
Member

I'll likely need it for #153721 to allow emitting the lint on one attribute at a time instead of each of the wrong values.

r? @JonathanBrouwer

@rustbot
Copy link
Copy Markdown
Collaborator

rustbot commented Apr 10, 2026

Some changes occurred in compiler/rustc_attr_parsing

cc @jdonszelmann, @JonathanBrouwer

rustc_error_messages was changed

cc @TaKO8Ki

@rustbot rustbot added A-attributes Area: Attributes (`#[…]`, `#![…]`) A-translation Area: Translation infrastructure, and migrating existing diagnostics to SessionDiagnostic S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Apr 10, 2026
@GuillaumeGomez
Copy link
Copy Markdown
Member Author

@bors try @rust-timer queue

@rust-timer

This comment has been minimized.

@rust-bors

This comment has been minimized.

rust-bors bot pushed a commit that referenced this pull request Apr 10, 2026
Make `rustc_attr_parsing::SharedContext::emit_lint` take a `MultiSpan` instead of a `Span`
@rustbot rustbot added the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Apr 10, 2026
Copy link
Copy Markdown
Contributor

@JonathanBrouwer JonathanBrouwer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

r=me if perf is not negative

View changes since this review

@rust-bors
Copy link
Copy Markdown
Contributor

rust-bors bot commented Apr 10, 2026

☀️ Try build successful (CI)
Build commit: 2b8e249 (2b8e249f759dc912717e595f314cf23795715abf, parent: 25a54d4ba87873ef02ef0e5fce49baa57198deb3)

@rust-timer

This comment has been minimized.

@rust-timer
Copy link
Copy Markdown
Collaborator

Finished benchmarking commit (2b8e249): comparison URL.

Overall result: no relevant changes - no action needed

Benchmarking means the PR may be perf-sensitive. It's automatically marked not fit for rolling up. Overriding is possible but disadvised: it risks changing compiler perf.

@bors rollup=never
@rustbot label: -S-waiting-on-perf -perf-regression

Instruction count

This perf run didn't have relevant results for this metric.

Max RSS (memory usage)

Results (primary 0.1%, secondary -0.6%)

A less reliable metric. May be of interest, but not used to determine the overall result above.

mean range count
Regressions ❌
(primary)
1.9% [1.7%, 2.1%] 2
Regressions ❌
(secondary)
5.0% [2.8%, 7.2%] 2
Improvements ✅
(primary)
-1.6% [-1.6%, -1.6%] 2
Improvements ✅
(secondary)
-3.5% [-6.2%, -2.0%] 4
All ❌✅ (primary) 0.1% [-1.6%, 2.1%] 4

Cycles

Results (secondary 3.3%)

A less reliable metric. May be of interest, but not used to determine the overall result above.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
3.3% [3.3%, 3.3%] 1
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) - - 0

Binary size

Results (primary -0.1%, secondary -0.0%)

A less reliable metric. May be of interest, but not used to determine the overall result above.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
-0.1% [-0.1%, -0.0%] 24
Improvements ✅
(secondary)
-0.0% [-0.1%, -0.0%] 17
All ❌✅ (primary) -0.1% [-0.1%, -0.0%] 24

Bootstrap: 488.4s -> 490.725s (0.48%)
Artifact size: 395.55 MiB -> 395.51 MiB (-0.01%)

@rustbot rustbot removed the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Apr 10, 2026
@GuillaumeGomez
Copy link
Copy Markdown
Member Author

Perfect. :3

@bors r=JonathanBrouwer rollup

@rust-bors
Copy link
Copy Markdown
Contributor

rust-bors bot commented Apr 10, 2026

📌 Commit 2c82731 has been approved by JonathanBrouwer

It is now in the queue for this repository.

@rust-bors rust-bors bot 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 Apr 10, 2026
rust-bors bot pushed a commit that referenced this pull request Apr 10, 2026
…uwer

Rollup of 6 pull requests

Successful merges:

 - #152901 (Introduce a `#[diagnostic::on_unknown]` attribute)
 - #155078 (Reject dangling attributes in where clauses)
 - #154449 (Invert dependency between `rustc_errors` and `rustc_abi`.)
 - #154646 (Add suggestion to `.to_owned()` used on `Cow` when borrowing)
 - #154993 (compiletest: pass -Zunstable-options for unpretty and no-codegen paths)
 - #155097 (Make `rustc_attr_parsing::SharedContext::emit_lint` take a `MultiSpan` instead of a `Span`)
rust-timer added a commit that referenced this pull request Apr 10, 2026
Rollup merge of #155097 - GuillaumeGomez:emit_lint-multispan, r=JonathanBrouwer

Make `rustc_attr_parsing::SharedContext::emit_lint` take a `MultiSpan` instead of a `Span`

I'll likely need it for #153721 to allow emitting the lint on one attribute at a time instead of each of the wrong values.

r? @JonathanBrouwer
@rust-bors rust-bors bot merged commit eb8e4f9 into rust-lang:main Apr 10, 2026
12 checks passed
@rustbot rustbot added this to the 1.96.0 milestone Apr 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-attributes Area: Attributes (`#[…]`, `#![…]`) A-translation Area: Translation infrastructure, and migrating existing diagnostics to SessionDiagnostic 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.

4 participants