diff options
| author | yukang <moorekang@gmail.com> | 2023-03-21 20:05:34 +0800 |
|---|---|---|
| committer | yukang <moorekang@gmail.com> | 2023-03-21 20:05:34 +0800 |
| commit | 7bffe945af456df6ad3294bdf82a67d727880adc (patch) | |
| tree | 344f8c145cfc5f2673445992191045406bc4a09e | |
| parent | 8126ccb77d5d7edd242a9f9566364b70f0a7b0a6 (diff) | |
| download | rust-7bffe945af456df6ad3294bdf82a67d727880adc.tar.gz rust-7bffe945af456df6ad3294bdf82a67d727880adc.zip | |
add delay_span_bug
| -rw-r--r-- | compiler/rustc_hir_typeck/src/upvar.rs | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/compiler/rustc_hir_typeck/src/upvar.rs b/compiler/rustc_hir_typeck/src/upvar.rs index 90947912a19..4847bddc38d 100644 --- a/compiler/rustc_hir_typeck/src/upvar.rs +++ b/compiler/rustc_hir_typeck/src/upvar.rs @@ -712,7 +712,13 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> { } } - // return Equal for two identical projections + self.tcx.sess.delay_span_bug( + closure_span, + &format!( + "two identical projections: ({:?}, {:?})", + capture1.place.projections, capture2.place.projections + ), + ); std::cmp::Ordering::Equal }); } |
