Skip to content

Arg splat experiment - HIR FnSig impl#157811

Open
teor2345 wants to merge 1 commit into
rust-lang:mainfrom
teor2345:fn-arg-splat-exp-fnsig
Open

Arg splat experiment - HIR FnSig impl#157811
teor2345 wants to merge 1 commit into
rust-lang:mainfrom
teor2345:fn-arg-splat-exp-fnsig

Conversation

@teor2345

Copy link
Copy Markdown
Contributor

View all comments

This PR is part of the argument splatting lang experiment, and FFI overloading / C++ interop project goals:

I've split it from #153697 to make reviewing easier, see that PR for more details.

The PR is the HIR-level FnSig implementation of the feature (next PR will be typecheck):

  • Add splat to HIR FnSig
    • which changes legacy mangling scheme function hashes due to the extra bytes
  • splat mismatch support, including function pretty-printing
  • various FIXME comments

Once this PR merges, I'll rebase #153697.

There aren't any extra tests in this PR, because it doesn't have any externally visible functionality. The visible functionality and tests are in the rest of #153697.

@rustbot

rustbot commented Jun 12, 2026

Copy link
Copy Markdown
Collaborator

HIR ty lowering was modified

cc @fmease

This PR changes rustc_public

cc @oli-obk, @celinval, @ouz-a, @makai410

rust-analyzer is developed in its own repository. If possible, consider making this change to rust-lang/rust-analyzer instead.

cc @rust-lang/rust-analyzer

miri is developed in its own repository. If possible, consider making this change to rust-lang/miri instead.

cc @rust-lang/miri

@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. T-rust-analyzer Relevant to the rust-analyzer team, which will review and decide on the PR/issue. labels Jun 12, 2026
@rustbot

rustbot commented Jun 12, 2026

Copy link
Copy Markdown
Collaborator

r? @dingxiangfei2009

rustbot has assigned @dingxiangfei2009.
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, types
  • compiler, types expanded to 73 candidates
  • Random selection from 19 candidates

#[type_foldable(identity)]
splatted: u16,

_marker: PhantomData<fn() -> I>,

@teor2345 teor2345 Jun 12, 2026

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

These attributes don't seem to be necessary, but should they be kept anyway?

Suggested change
_marker: PhantomData<fn() -> I>,
#[type_visitable(ignore)]
#[type_foldable(identity)]
_marker: PhantomData<fn() -> I>,

View changes since the review

@rust-bors

rust-bors Bot commented Jun 13, 2026

Copy link
Copy Markdown
Contributor

☔ The latest upstream changes (presumably #157863) made this pull request unmergeable. Please resolve the merge conflicts.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

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. T-rust-analyzer Relevant to the rust-analyzer team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants