Skip to content

#[target_feature] is allowed on main #108645

Closed
@LeSeulArtichaut

Description

#[target_feature(enable = "avx2")] // no error
fn main() {}

This is a consequence of #[target_feature] being allowed on safe functions with #![feature(target_feature_11)].

cc #69098
@rustbot label T-lang T-compiler C-bug I-unsound F-target_feature_11

Metadata

Labels

A-target-featureArea: Enabling/disabling target features like AVX, Neon, etc.C-bugCategory: This is a bug.F-target_feature_11target feature 1.1 RFCI-unsoundIssue: A soundness hole (worst kind of bug), see: https://en.wikipedia.org/wiki/SoundnessP-highHigh priorityT-compilerRelevant to the compiler team, which will review and decide on the PR/issue.T-langRelevant to the language team, which will review and decide on the PR/issue.requires-nightlyThis issue requires a nightly compiler in some way.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions