From bd1a1e4f0d2f3fbd0788f30370437ffcbca0c777 Mon Sep 17 00:00:00 2001 From: Cameron Steffen Date: Thu, 14 Oct 2021 16:19:39 -0500 Subject: [PATCH 1/3] Don't mark for loop head span with desugaring --- compiler/rustc_ast_lowering/src/expr.rs | 15 ++--- .../src/diagnostics/conflict_errors.rs | 60 +++++++++---------- .../src/diagnostics/move_errors.rs | 21 +++---- compiler/rustc_lint/src/array_into_iter.rs | 3 +- src/test/incremental/hashes/for_loops.rs | 2 +- 5 files changed, 48 insertions(+), 53 deletions(-) diff --git a/compiler/rustc_ast_lowering/src/expr.rs b/compiler/rustc_ast_lowering/src/expr.rs index 6027027428eee..bc8ea4fb5efa5 100644 --- a/compiler/rustc_ast_lowering/src/expr.rs +++ b/compiler/rustc_ast_lowering/src/expr.rs @@ -1331,15 +1331,10 @@ impl<'hir> LoweringContext<'_, 'hir> { body: &Block, opt_label: Option