Skip to content

Commit 6bbea3d

Browse files
authored
Rollup merge of #154752 - theemathas:comment, r=lcnr
Add comment to borrow-checker As requested by @lcnr r? @lcnr
2 parents a135a5a + 707c0d0 commit 6bbea3d

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

  • compiler/rustc_borrowck/src/type_check

compiler/rustc_borrowck/src/type_check/mod.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -447,6 +447,8 @@ impl<'a, 'tcx> TypeChecker<'a, 'tcx> {
447447
let tcx = self.infcx.tcx;
448448

449449
for proj in &user_ty.projs {
450+
// Necessary for non-trivial patterns whose user-type annotation is an opaque type,
451+
// e.g. `let (_a,): Tait = whatever`, see #105897
450452
if !self.infcx.next_trait_solver()
451453
&& let ty::Alias(ty::Opaque, ..) = curr_projected_ty.ty.kind()
452454
{

0 commit comments

Comments
 (0)