Landing: ff64d77c9a37

Project / Subsystem

gcc / gccrs

Date

2026-05-19

Author

Egas Ribeiro

Commit

ff64d77c9a37c716b7b4ca0a6b5920626ff34360

Source

github

Perf win

No

Breaking

No

All attributes

project
gcc
subsystem
gccrs
patch_id
—
commit_hash
ff64d77c9a37c716b7b4ca0a6b5920626ff34360
source_type
github
headline
Enforce irrefutability in Rust let bindings and parameters using gccrs
tldr
gccrs now diagnoses refutable patterns in non-optional let bindings and function parameters.
author
Egas Ribeiro
outcome
committed
performance_win
false
breaking_change
false
series_id
—
series_parts
[]
tags
  • • rust
  • • compiler
  • • pattern matching
  • • safety
discussion_id_link
—
bugzilla_pr
—
date
2026-05-19T00:00:00.000Z

gccrs enforces the rule that let bindings (without an else clause) and function parameters must use irrefutable patterns. The compiler now issues diagnostics for refutable patterns in these contexts, deferring comprehensive checks to the PatternChecker after type information is available. This improves compile-time safety by preventing non-exhaustive pattern matches where they are not permitted.