`rustc_splat` is not feature gated in functions without bodies
Open
@JonathanBrouwer is already working on this.
Since Sep 11, 2026.
A-attributes
C-bug
F-splat
I-ICE
regression-from-stable-to-stable
T-compiler
- Dominant language
- Rust
- Stars
- 119k
- Forks
- 16.1k
- PR merge metrics
- PR metrics pending
Description
I tried this code:
fn help(x: fn(#[rustc_splat(this = completely invalid $$$)] usize)) {
}
I expected to see this happen: compilation fails because rustc_splat is unstable
Instead, this happened: the code compiles
Meta
rustc --version --verbose:
rustc 1.98.0 (88d9e12ae 2026-08-18)
binary: rustc
commit-hash: 88d9e12ae178fab0fb5cc050a94da85685d449ea
commit-date: 2026-08-18
host: x86_64-unknown-linux-gnu
release: 1.98.0
LLVM version: 22.1.8
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.