diff options
Diffstat (limited to 'crates/ra_hir/src/expr')
-rw-r--r-- | crates/ra_hir/src/expr/lower.rs | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/crates/ra_hir/src/expr/lower.rs b/crates/ra_hir/src/expr/lower.rs index 50ea429ea..24733b3de 100644 --- a/crates/ra_hir/src/expr/lower.rs +++ b/crates/ra_hir/src/expr/lower.rs | |||
@@ -16,7 +16,7 @@ use crate::{ | |||
16 | path::GenericArgs, | 16 | path::GenericArgs, |
17 | ty::primitive::{FloatTy, IntTy, UncertainFloatTy, UncertainIntTy}, | 17 | ty::primitive::{FloatTy, IntTy, UncertainFloatTy, UncertainIntTy}, |
18 | type_ref::TypeRef, | 18 | type_ref::TypeRef, |
19 | DefWithBody, Either, HirFileId, MacroCallLoc, MacroFileKind, Mutability, Path, Resolver, | 19 | AstId, DefWithBody, Either, HirFileId, MacroCallLoc, MacroFileKind, Mutability, Path, Resolver, |
20 | Source, | 20 | Source, |
21 | }; | 21 | }; |
22 | 22 | ||
@@ -458,11 +458,10 @@ where | |||
458 | ast::Expr::Label(_e) => self.alloc_expr(Expr::Missing, syntax_ptr), | 458 | ast::Expr::Label(_e) => self.alloc_expr(Expr::Missing, syntax_ptr), |
459 | ast::Expr::RangeExpr(_e) => self.alloc_expr(Expr::Missing, syntax_ptr), | 459 | ast::Expr::RangeExpr(_e) => self.alloc_expr(Expr::Missing, syntax_ptr), |
460 | ast::Expr::MacroCall(e) => { | 460 | ast::Expr::MacroCall(e) => { |
461 | let ast_id = self | 461 | let ast_id = AstId::new( |
462 | .db | 462 | self.current_file_id, |
463 | .ast_id_map(self.current_file_id) | 463 | self.db.ast_id_map(self.current_file_id).ast_id(&e), |
464 | .ast_id(&e) | 464 | ); |
465 | .with_file_id(self.current_file_id); | ||
466 | 465 | ||
467 | if let Some(path) = e.path().and_then(|path| self.parse_path(path)) { | 466 | if let Some(path) = e.path().and_then(|path| self.parse_path(path)) { |
468 | if let Some(def) = self.resolver.resolve_path_as_macro(self.db, &path) { | 467 | if let Some(def) = self.resolver.resolve_path_as_macro(self.db, &path) { |