Open
Description
openedon Oct 25, 2019
The reference states that custom derive macros support defined helper attributes:
#[proc_macro_derive(HelperAttr, attributes(helper))]
pub fn derive_helper_attr(_item: TokenStream) -> TokenStream {
TokenStream::new()
}
However, the same does not appear to apply to proc_macro_attribute
. Please extend it to do so.
#[proc_macro_attribute(attributes(helper))]
pub fn my_attribute(attr: TokenStream, item: TokenStream) -> TokenStream { .. }
Motivation is limited, but this could provide simpler specification here.
Related: #53012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment