expand: Leave traces when expanding cfg
attributes
This commit is contained in:
parent
65899c06f1
commit
92d802eda6
24 changed files with 88 additions and 108 deletions
|
@ -760,10 +760,14 @@ pub static BUILTIN_ATTRIBUTES: &[BuiltinAttribute] = &[
|
|||
template!(Word, List: r#""...""#), DuplicatesOk,
|
||||
EncodeCrossCrate::Yes, INTERNAL_UNSTABLE
|
||||
),
|
||||
// Trace that is left when a `cfg_attr` attribute is expanded.
|
||||
// The attribute is not gated, to avoid stability errors, but it cannot be used in stable or
|
||||
// unstable code directly because `sym::cfg_attr_trace` is not a valid identifier, it can only
|
||||
// be generated by the compiler.
|
||||
// Traces that are left when `cfg` and `cfg_attr` attributes are expanded.
|
||||
// The attributes are not gated, to avoid stability errors, but they cannot be used in stable
|
||||
// or unstable code directly because `sym::cfg_(attr_)trace` are not valid identifiers, they
|
||||
// can only be generated by the compiler.
|
||||
ungated!(
|
||||
cfg_trace, Normal, template!(Word /* irrelevant */), DuplicatesOk,
|
||||
EncodeCrossCrate::No
|
||||
),
|
||||
ungated!(
|
||||
cfg_attr_trace, Normal, template!(Word /* irrelevant */), DuplicatesOk,
|
||||
EncodeCrossCrate::No
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue