Landing: a54310bd1773

Project / Subsystem

gcc / gccrs

Date

2026-09-11

Author

Philip Herron

Commit

a54310bd17730fd589568941962610bc85dd251b

Source

github

Perf win

No

Breaking

No

All attributes

project
gcc
subsystem
gccrs
patch_id
—
commit_hash
a54310bd17730fd589568941962610bc85dd251b
source_type
github
headline
gccrs: Implements shim for legacy const generics attribute
tldr
gccrs adds a workaround for Rust's `#[rustc_legacy_const_generics]` attribute to support older code patterns.
author
Philip Herron
outcome
committed
performance_win
false
breaking_change
false
series_id
—
series_parts
[]
tags
  • • gccrs
  • • rust
  • • const-generics
  • • compat
  • • stdarch
discussion_id_link
—
bugzilla_pr
—
date
2026-09-11T00:00:00.000Z

This commit introduces a workaround in gccrs for Rust’s #[rustc_legacy_const_generics] attribute, which is necessary for compiling certain parts of stdarch. This attribute is a legacy feature used to enable const generics in older Rust code. The implemented shim provides a starting point for handling these constructs, although it doesn’t fully implement the attribute’s behavior. The change adjusts type cast rules and adds related attributes.