diff --git a/crates/ra_hir_def/src/body.rs b/crates/ra_hir_def/src/body.rs index d4cab056140..332c509e170 100644 --- a/crates/ra_hir_def/src/body.rs +++ b/crates/ra_hir_def/src/body.rs @@ -17,7 +17,7 @@ use crate::{ nameres::{BuiltinShadowMode, CrateDefMap}, path::{ModPath, Path}, src::HasSource, - DefWithBodyId, HasModule, Lookup, ModuleId, + DefWithBodyId, HasModule, Lookup, ModuleDefId, ModuleId, }; struct Expander { @@ -119,6 +119,7 @@ pub struct Body { pub params: Vec, /// The `ExprId` of the actual body expression. pub body_expr: ExprId, + pub defs: Vec, } pub type ExprPtr = Either, AstPtr>; diff --git a/crates/ra_hir_def/src/body/lower.rs b/crates/ra_hir_def/src/body/lower.rs index 61193b4d804..86960186f19 100644 --- a/crates/ra_hir_def/src/body/lower.rs +++ b/crates/ra_hir_def/src/body/lower.rs @@ -41,6 +41,7 @@ pub(super) fn lower( pats: Arena::default(), params: Vec::new(), body_expr: ExprId::dummy(), + defs: Vec::new(), }, } .collect(params, body)