Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/hir-def/src/expander.rs')
| -rw-r--r-- | crates/hir-def/src/expander.rs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/crates/hir-def/src/expander.rs b/crates/hir-def/src/expander.rs index dbf8e6b225..d1640ad7e5 100644 --- a/crates/hir-def/src/expander.rs +++ b/crates/hir-def/src/expander.rs @@ -10,6 +10,7 @@ use hir_expand::{ InFile, MacroCallId, }; use limit::Limit; +use span::SyntaxContextId; use syntax::{ast, Parse}; use triomphe::Arc; @@ -52,6 +53,11 @@ impl Expander { self.module.krate } + pub fn syntax_context(&self) -> SyntaxContextId { + // FIXME: + SyntaxContextId::ROOT + } + pub fn enter_expand<T: ast::AstNode>( &mut self, db: &dyn DefDatabase, |