8000 Rollup of 5 pull requests by Dylan-DPC-zz · Pull Request #71549 · rust-lang/rust · GitHub
[go: up one dir, main page]

Skip to content

Rollup of 5 pull requests #71549

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 13 commits into from
Apr 25, 2020
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Use correct span on while (let) lowering
  • Loading branch information
flip1995 committed Apr 23, 2020
commit 602f206408bea967f0f3934d14b918a43a11845d
8 changes: 2 additions & 6 deletions src/librustc_ast_lowering/expr.rs
Original file line number Diff line number Diff line change
Expand Up @@ -397,12 +397,8 @@ impl<'hir> LoweringContext<'_, 'hir> {
let then_arm = self.arm(then_pat, self.arena.alloc(then_expr));

// `match <scrutinee> { ... }`
let match_expr = self.expr_match(
scrutinee.span,
scrutinee,
arena_vec![self; then_arm, else_arm],
desugar,
);
let match_expr =
self.expr_match(span, scrutinee, arena_vec![self; then_arm, else_arm], desugar);

// `[opt_ident]: loop { ... }`
hir::ExprKind::Loop(self.block_expr(self.arena.alloc(match_expr)), opt_label, source)
Expand Down
0