pub struct PureMacro {
pub path: String,
pub name: Option<String>,
pub delimiter: MacroDelimiter,
pub tokens: String,
}Expand description
A macro invocation at item level.
Fields§
§path: StringMacro path.
name: Option<String>Optional definition name. Set for macro_rules! NAME { ... } — syn
stores this on ItemMacro.ident rather than inside mac.path. For
regular call-site macros (println!, vec!, html!) this is None.
Without this field, macro_rules! square { ... } round-trips into
nameless macro_rules! { ... }.
delimiter: MacroDelimiterDelimiter used.
tokens: StringTokens inside (as string).
Trait Implementations§
impl Eq for PureMacro
impl StructuralPartialEq for PureMacro
Auto Trait Implementations§
impl Freeze for PureMacro
impl RefUnwindSafe for PureMacro
impl Send for PureMacro
impl Sync for PureMacro
impl Unpin for PureMacro
impl UnsafeUnpin for PureMacro
impl UnwindSafe for PureMacro
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more