summaryrefslogtreecommitdiffstats
path: root/compiler/rustc_ast_lowering/src/index.rs
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/rustc_ast_lowering/src/index.rs')
-rw-r--r--compiler/rustc_ast_lowering/src/index.rs8
1 files changed, 8 insertions, 0 deletions
diff --git a/compiler/rustc_ast_lowering/src/index.rs b/compiler/rustc_ast_lowering/src/index.rs
index 2e66c81eb..ce847906f 100644
--- a/compiler/rustc_ast_lowering/src/index.rs
+++ b/compiler/rustc_ast_lowering/src/index.rs
@@ -223,6 +223,14 @@ impl<'a, 'hir> Visitor<'hir> for NodeCollector<'a, 'hir> {
});
}
+ fn visit_inline_const(&mut self, constant: &'hir ConstBlock) {
+ self.insert(DUMMY_SP, constant.hir_id, Node::ConstBlock(constant));
+
+ self.with_parent(constant.hir_id, |this| {
+ intravisit::walk_inline_const(this, constant);
+ });
+ }
+
fn visit_expr(&mut self, expr: &'hir Expr<'hir>) {
self.insert(expr.span, expr.hir_id, Node::Expr(expr));