diff options
| author | Mazdak Farrokhzad <twingoow@gmail.com> | 2019-08-10 17:26:11 +0200 |
|---|---|---|
| committer | Mazdak Farrokhzad <twingoow@gmail.com> | 2019-08-10 20:24:43 +0200 |
| commit | e71f6e1fbcb41572b72ea266cce53a14e8be432b (patch) | |
| tree | 7132c94c072e63c9827cf793b12644111354511e | |
| parent | 94876c22dbb28abd2ff9f1c961770f54682480a7 (diff) | |
| download | rust-e71f6e1fbcb41572b72ea266cce53a14e8be432b.tar.gz rust-e71f6e1fbcb41572b72ea266cce53a14e8be432b.zip | |
lowering: move lower_field -> expr.rs
| -rw-r--r-- | src/librustc/hir/lowering.rs | 10 | ||||
| -rw-r--r-- | src/librustc/hir/lowering/expr.rs | 10 |
2 files changed, 10 insertions, 10 deletions
diff --git a/src/librustc/hir/lowering.rs b/src/librustc/hir/lowering.rs index e93a81d74fd..d1b3f15c708 100644 --- a/src/librustc/hir/lowering.rs +++ b/src/librustc/hir/lowering.rs @@ -3124,16 +3124,6 @@ impl<'a> LoweringContext<'a> { } } - fn lower_field(&mut self, f: &Field) -> hir::Field { - hir::Field { - hir_id: self.next_id(), - ident: f.ident, - expr: P(self.lower_expr(&f.expr)), - span: f.span, - is_shorthand: f.is_shorthand, - } - } - fn lower_mt(&mut self, mt: &MutTy, itctx: ImplTraitContext<'_>) -> hir::MutTy { hir::MutTy { ty: self.lower_ty(&mt.ty, itctx), diff --git a/src/librustc/hir/lowering/expr.rs b/src/librustc/hir/lowering/expr.rs index 0092616cc39..5533432d13d 100644 --- a/src/librustc/hir/lowering/expr.rs +++ b/src/librustc/hir/lowering/expr.rs @@ -818,6 +818,16 @@ impl LoweringContext<'_> { hir::ExprKind::InlineAsm(P(hir_asm), outputs, inputs) } + fn lower_field(&mut self, f: &Field) -> hir::Field { + hir::Field { + hir_id: self.next_id(), + ident: f.ident, + expr: P(self.lower_expr(&f.expr)), + span: f.span, + is_shorthand: f.is_shorthand, + } + } + fn lower_expr_yield(&mut self, span: Span, opt_expr: Option<&Expr>) -> hir::ExprKind { match self.generator_kind { Some(hir::GeneratorKind::Gen) => {}, |
