Skip to content

Use an unexpanded span for actually written down opt out params#158258

Merged
rust-bors[bot] merged 1 commit into
rust-lang:mainfrom
oli-obk:opt-out-bound-span
Jun 22, 2026
Merged

Use an unexpanded span for actually written down opt out params#158258
rust-bors[bot] merged 1 commit into
rust-lang:mainfrom
oli-obk:opt-out-bound-span

Conversation

@oli-obk

@oli-obk oli-obk commented Jun 22, 2026

Copy link
Copy Markdown
Contributor

I'm trying to land the components of #158122 individually now (and fixing the bugs in the process).

TLDR: we didn't use the span of ?Sized for generating other default bounds of the sized hierarchy, causing in funky diagnostics, this PR fixes that

@oli-obk oli-obk added the F-sized_hierarchy `#![feature(sized_hierarchy)]` label Jun 22, 2026
@rustbot

rustbot commented Jun 22, 2026

Copy link
Copy Markdown
Collaborator

HIR ty lowering was modified

cc @fmease

@rustbot rustbot added 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 Jun 22, 2026
@rustbot

rustbot commented Jun 22, 2026

Copy link
Copy Markdown
Collaborator

r? @chenyukang

rustbot has assigned @chenyukang.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

Why was this reviewer chosen?

The reviewer was selected based on:

  • Owners of files modified in this PR: compiler
  • compiler expanded to 73 candidates
  • Random selection from 20 candidates

| ^ unused type parameter
|
= help: consider removing `N` or referring to it in the body of the type alias
= help: if you intended `N` to be a const parameter, use `const N: /* Type */` instead

@camelid camelid Jun 22, 2026

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Any idea why this disappeared?

View changes since the review

@camelid camelid Jun 22, 2026

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Ah, I see it was discussed here #157702 (comment).

@camelid camelid left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

r=me when CI passes

View changes since this review

@camelid camelid assigned camelid and unassigned chenyukang Jun 22, 2026
@camelid

camelid commented Jun 22, 2026

Copy link
Copy Markdown
Member

@bors r+ rollup

@rust-bors

rust-bors Bot commented Jun 22, 2026

Copy link
Copy Markdown
Contributor

📌 Commit cf5f9f1 has been approved by camelid

It is now in the queue for this repository.

🌲 The tree is currently closed for pull requests below priority 5. This pull request will be tested once the tree is reopened.

@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 Jun 22, 2026
JonathanBrouwer added a commit to JonathanBrouwer/rust that referenced this pull request Jun 22, 2026
Use an unexpanded span for actually written down opt out params

I'm trying to land the components of rust-lang#158122 individually now (and fixing the bugs in the process).

TLDR: we didn't use the span of `?Sized` for generating other default bounds of the sized hierarchy, causing in funky diagnostics, this PR fixes that
rust-bors Bot pushed a commit that referenced this pull request Jun 22, 2026
…uwer

Rollup of 7 pull requests

Successful merges:

 - #157983 (Lift the same-signature restriction for `extern "tail"`)
 - #158242 (Fix linking for wasm with crate metadata included)
 - #158119 (Refactor `proc_macro_decls_static`)
 - #158172 (update `asm_experimental_reg` comments)
 - #158230 (Include `Item::stability` info in rustdoc JSON.)
 - #158258 (Use an unexpanded span for actually written down opt out params)
 - #158262 (Change compiler leads in triagebot.toml)
rust-bors Bot pushed a commit that referenced this pull request Jun 22, 2026
…uwer

Rollup of 8 pull requests

Successful merges:

 - #158242 (Fix linking for wasm with crate metadata included)
 - #157978 (Avoid `&raw` recovery ICE after trailing comma)
 - #158119 (Refactor `proc_macro_decls_static`)
 - #158171 (rustdoc: Avoid ICE on unevaluated `type const` projections in array lengths)
 - #158172 (update `asm_experimental_reg` comments)
 - #158230 (Include `Item::stability` info in rustdoc JSON.)
 - #158258 (Use an unexpanded span for actually written down opt out params)
 - #158262 (Change compiler leads in triagebot.toml)
rust-bors Bot pushed a commit that referenced this pull request Jun 22, 2026
…uwer

Rollup of 8 pull requests

Successful merges:

 - #158242 (Fix linking for wasm with crate metadata included)
 - #157978 (Avoid `&raw` recovery ICE after trailing comma)
 - #158119 (Refactor `proc_macro_decls_static`)
 - #158171 (rustdoc: Avoid ICE on unevaluated `type const` projections in array lengths)
 - #158172 (update `asm_experimental_reg` comments)
 - #158230 (Include `Item::stability` info in rustdoc JSON.)
 - #158258 (Use an unexpanded span for actually written down opt out params)
 - #158262 (Change compiler leads in triagebot.toml)
rust-bors Bot pushed a commit that referenced this pull request Jun 22, 2026
…uwer

Rollup of 8 pull requests

Successful merges:

 - #158242 (Fix linking for wasm with crate metadata included)
 - #157978 (Avoid `&raw` recovery ICE after trailing comma)
 - #158119 (Refactor `proc_macro_decls_static`)
 - #158171 (rustdoc: Avoid ICE on unevaluated `type const` projections in array lengths)
 - #158172 (update `asm_experimental_reg` comments)
 - #158230 (Include `Item::stability` info in rustdoc JSON.)
 - #158258 (Use an unexpanded span for actually written down opt out params)
 - #158262 (Change compiler leads in triagebot.toml)
rust-bors Bot pushed a commit that referenced this pull request Jun 22, 2026
…uwer

Rollup of 8 pull requests

Successful merges:

 - #158242 (Fix linking for wasm with crate metadata included)
 - #157978 (Avoid `&raw` recovery ICE after trailing comma)
 - #158119 (Refactor `proc_macro_decls_static`)
 - #158171 (rustdoc: Avoid ICE on unevaluated `type const` projections in array lengths)
 - #158172 (update `asm_experimental_reg` comments)
 - #158230 (Include `Item::stability` info in rustdoc JSON.)
 - #158258 (Use an unexpanded span for actually written down opt out params)
 - #158262 (Change compiler leads in triagebot.toml)
@rust-bors rust-bors Bot merged commit 9bb32de into rust-lang:main Jun 22, 2026
13 checks passed
@rustbot rustbot added this to the 1.98.0 milestone Jun 22, 2026
rust-timer added a commit that referenced this pull request Jun 22, 2026
Rollup merge of #158258 - oli-obk:opt-out-bound-span, r=camelid

Use an unexpanded span for actually written down opt out params

I'm trying to land the components of #158122 individually now (and fixing the bugs in the process).

TLDR: we didn't use the span of `?Sized` for generating other default bounds of the sized hierarchy, causing in funky diagnostics, this PR fixes that
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

F-sized_hierarchy `#![feature(sized_hierarchy)]` 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