aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_hir_expand/src/lib.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ra_hir_expand/src/lib.rs')
-rw-r--r--crates/ra_hir_expand/src/lib.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/crates/ra_hir_expand/src/lib.rs b/crates/ra_hir_expand/src/lib.rs
index d9e31ac20..2e8d63691 100644
--- a/crates/ra_hir_expand/src/lib.rs
+++ b/crates/ra_hir_expand/src/lib.rs
@@ -159,7 +159,7 @@ impl HirFileId {
159 } 159 }
160 160
161 /// Indicate it is macro file generated for builtin derive 161 /// Indicate it is macro file generated for builtin derive
162 pub fn is_builtin_derive(&self, db: &dyn db::AstDatabase) -> Option<InFile<ast::ModuleItem>> { 162 pub fn is_builtin_derive(&self, db: &dyn db::AstDatabase) -> Option<InFile<ast::Item>> {
163 match self.0 { 163 match self.0 {
164 HirFileIdRepr::FileId(_) => None, 164 HirFileIdRepr::FileId(_) => None,
165 HirFileIdRepr::MacroFile(macro_file) => { 165 HirFileIdRepr::MacroFile(macro_file) => {
@@ -174,7 +174,7 @@ impl HirFileId {
174 MacroDefKind::BuiltInDerive(_) => loc.kind.node(db), 174 MacroDefKind::BuiltInDerive(_) => loc.kind.node(db),
175 _ => return None, 175 _ => return None,
176 }; 176 };
177 Some(item.with_value(ast::ModuleItem::cast(item.value.clone())?)) 177 Some(item.with_value(ast::Item::cast(item.value.clone())?))
178 } 178 }
179 } 179 }
180 } 180 }
@@ -258,7 +258,7 @@ pub struct MacroCallLoc {
258#[derive(Debug, Clone, PartialEq, Eq, Hash)] 258#[derive(Debug, Clone, PartialEq, Eq, Hash)]
259pub enum MacroCallKind { 259pub enum MacroCallKind {
260 FnLike(AstId<ast::MacroCall>), 260 FnLike(AstId<ast::MacroCall>),
261 Attr(AstId<ast::ModuleItem>, String), 261 Attr(AstId<ast::Item>, String),
262} 262}
263 263
264impl MacroCallKind { 264impl MacroCallKind {