Deny unsafe on more builtin attributes

This commit is contained in:
carbotaniuman
2024-07-02 23:52:16 -05:00
parent 368e2fd458
commit d8bc8761a5
11 changed files with 307 additions and 58 deletions

View File

@@ -17,11 +17,13 @@ pub(crate) fn check_builtin_macro_attribute(ecx: &ExtCtxt<'_>, meta_item: &MetaI
// All the built-in macro attributes are "words" at the moment.
let template = AttributeTemplate { word: true, ..Default::default() };
validate_attr::check_builtin_meta_item(
&ecx.ecfg.features,
&ecx.sess.psess,
meta_item,
AttrStyle::Outer,
name,
template,
true,
);
}