-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Closed
Labels
C-bugCategory: This is a bug.Category: This is a bug.F-const_generics`#![feature(const_generics)]``#![feature(const_generics)]`
Description
#![feature(min_const_generics)]
pub struct Foo<#[inline] const N: usize>;
pub struct Bar<#[cold] const N: usize>;
pub struct Baz<#[repr(C)] const N: usize>;
results in
warning: unused attribute
--> src/lib.rs:5:16
|
5 | pub struct Baz<#[repr(C)] const N: usize>;
| ^^^^^^^^^^
|
= note: `#[warn(unused_attributes)]` on by default
So inline
and cold
are silently accepted and repr(C)
only results in a lint.
All of these cases should error. Fixing this after stabilization would be an - although small - backcompat issue.
Blocking stabilization on this for now.
Metadata
Metadata
Assignees
Labels
C-bugCategory: This is a bug.Category: This is a bug.F-const_generics`#![feature(const_generics)]``#![feature(const_generics)]`