diff options
| author | Santiago Pastorino <spastorino@gmail.com> | 2020-10-06 16:58:53 -0300 |
|---|---|---|
| committer | Santiago Pastorino <spastorino@gmail.com> | 2020-10-16 15:21:16 -0300 |
| commit | 66e254314d7fbb0defa2feb3b56ab212aafae933 (patch) | |
| tree | 723c4c7633cdb56f41f90441f3787d93f842f755 /compiler/rustc_ast_lowering | |
| parent | 59d07c3ae5a1f53924c7580fa302c397c362f1a2 (diff) | |
| download | rust-66e254314d7fbb0defa2feb3b56ab212aafae933.tar.gz rust-66e254314d7fbb0defa2feb3b56ab212aafae933.zip | |
Lower inline const's AST to HIR
Diffstat (limited to 'compiler/rustc_ast_lowering')
| -rw-r--r-- | compiler/rustc_ast_lowering/src/expr.rs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/compiler/rustc_ast_lowering/src/expr.rs b/compiler/rustc_ast_lowering/src/expr.rs index 1841a06eb89..0995231c639 100644 --- a/compiler/rustc_ast_lowering/src/expr.rs +++ b/compiler/rustc_ast_lowering/src/expr.rs @@ -30,8 +30,9 @@ impl<'hir> LoweringContext<'_, 'hir> { let kind = match e.kind { ExprKind::Box(ref inner) => hir::ExprKind::Box(self.lower_expr(inner)), ExprKind::Array(ref exprs) => hir::ExprKind::Array(self.lower_exprs(exprs)), - ExprKind::ConstBlock(_) => { - unimplemented!(); + ExprKind::ConstBlock(ref anon_const) => { + let anon_const = self.lower_anon_const(anon_const); + hir::ExprKind::ConstBlock(anon_const) } ExprKind::Repeat(ref expr, ref count) => { let expr = self.lower_expr(expr); |
