Skip to content

Reject empty cfg_attr - #4077

Merged
P-E-P merged 1 commit into
Rust-GCC:masterfrom
P-E-P:empty_cfg_attr
Aug 14, 2025
Merged

Reject empty cfg_attr#4077
P-E-P merged 1 commit into
Rust-GCC:masterfrom
P-E-P:empty_cfg_attr

Conversation

@P-E-P

@P-E-P P-E-P commented Aug 13, 2025

Copy link
Copy Markdown
Member

Fixes #3966

@P-E-P
P-E-P requested a review from powerboat9 August 13, 2025 16:48
Comment thread gcc/rust/ast/rust-ast.cc Outdated
gcc/rust/ChangeLog:

	* ast/rust-ast.cc (Attribute::check_cfg_predicate): Emit an error with
	empty cfg_attr input.

gcc/testsuite/ChangeLog:

	* rust/compile/issue-3966.rs: New test.

Signed-off-by: Pierre-Emmanuel Patry <pierre-emmanuel.patry@embecosm.com>
@P-E-P
P-E-P enabled auto-merge August 14, 2025 10:33
@P-E-P
P-E-P added this pull request to the merge queue Aug 14, 2025
auto-merge was automatically disabled August 14, 2025 11:07

Pull Request is not mergeable

Merged via the queue into Rust-GCC:master with commit e4a7b46 Aug 14, 2025
13 checks passed
@P-E-P
P-E-P deleted the empty_cfg_attr branch November 26, 2025 12:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

segfault with cfg_attr on struct field

2 participants