-
-
Notifications
You must be signed in to change notification settings - Fork 14.4k
Description
Under feature(min_generic_const_args) const items have been split into two, "const items" and "type const items". Type const items are written with the #[type_const] attribute applied to the syntax of a normal const item.
In some places in the compiler we check whether a DefId is a type const by looking at its attributes, in other places we call tcx.is_type_const. Everywhere that currently looks at attributes to determine if a const item is a type const item should be changed to use .is_type_const.
This should make it easier to read some of the logic and also make it easier to switch out the type_const attribute for some other means of determining whether a const item is a type const or not. Searching for AttributeKind::TypeConst in the compiler should yield all the places that need updating.