Trait MacroFileIdExt
pub trait MacroFileIdExt {
// Required methods
fn is_env_or_option_env(&self, db: &(dyn ExpandDatabase + 'static)) -> bool;
fn is_include_like_macro(&self, db: &(dyn ExpandDatabase + 'static)) -> bool;
fn eager_arg(
&self,
db: &(dyn ExpandDatabase + 'static),
) -> Option<MacroCallId>;
fn expansion_level(self, db: &(dyn ExpandDatabase + 'static)) -> u32;
fn call_node(
self,
db: &(dyn ExpandDatabase + 'static),
) -> InFileWrapper<HirFileId, SyntaxNode<RustLanguage>>;
fn parent(self, db: &(dyn ExpandDatabase + 'static)) -> HirFileId;
fn expansion_info(
self,
db: &(dyn ExpandDatabase + 'static),
) -> ExpansionInfo;
fn kind(&self, db: &(dyn ExpandDatabase + 'static)) -> MacroKind;
fn is_include_macro(&self, db: &(dyn ExpandDatabase + 'static)) -> bool;
fn is_eager(&self, db: &(dyn ExpandDatabase + 'static)) -> bool;
fn is_derive_attr_pseudo_expansion(
&self,
db: &(dyn ExpandDatabase + 'static),
) -> bool;
}
Required Methods§
fn is_env_or_option_env(&self, db: &(dyn ExpandDatabase + 'static)) -> bool
fn is_include_like_macro(&self, db: &(dyn ExpandDatabase + 'static)) -> bool
fn eager_arg(&self, db: &(dyn ExpandDatabase + 'static)) -> Option<MacroCallId>
fn expansion_level(self, db: &(dyn ExpandDatabase + 'static)) -> u32
fn call_node(
self,
db: &(dyn ExpandDatabase + 'static),
) -> InFileWrapper<HirFileId, SyntaxNode<RustLanguage>>
fn call_node( self, db: &(dyn ExpandDatabase + 'static), ) -> InFileWrapper<HirFileId, SyntaxNode<RustLanguage>>
If this is a macro call, returns the syntax node of the call.
fn parent(self, db: &(dyn ExpandDatabase + 'static)) -> HirFileId
fn expansion_info(self, db: &(dyn ExpandDatabase + 'static)) -> ExpansionInfo
fn kind(&self, db: &(dyn ExpandDatabase + 'static)) -> MacroKind
fn is_include_macro(&self, db: &(dyn ExpandDatabase + 'static)) -> bool
fn is_include_macro(&self, db: &(dyn ExpandDatabase + 'static)) -> bool
Return whether this file is an include macro
fn is_eager(&self, db: &(dyn ExpandDatabase + 'static)) -> bool
fn is_derive_attr_pseudo_expansion(
&self,
db: &(dyn ExpandDatabase + 'static),
) -> bool
fn is_derive_attr_pseudo_expansion( &self, db: &(dyn ExpandDatabase + 'static), ) -> bool
Return whether this file is the pseudo expansion of the derive attribute.
See [crate::builtin_attr_macro::derive_attr_expand
].