]> git.lizzy.rs Git - rust.git/commit
Auto merge of #81717 - Aaron1011:fix/closure-diag, r=estebank
authorbors <bors@rust-lang.org>
Wed, 3 Feb 2021 20:53:08 +0000 (20:53 +0000)
committerbors <bors@rust-lang.org>
Wed, 3 Feb 2021 20:53:08 +0000 (20:53 +0000)
commite708cbd91c9cae4426d69270248362b423324556
tree292389d778b37e739023f2df6a70edb2a7b9c83d
parent120b2a704a60d4341286bd82f6e638c65ca169b6
parentbc84e211075e4c53e6fd122353f3132939e45ff9
Auto merge of #81717 - Aaron1011:fix/closure-diag, r=estebank

Fix panic when emitting diagnostic for closure mutable binding error

Fixes #81700

The upvar borrow kind may be `ty::BorrowKind::UniqueImmBorrow`, which is
still a mutable borrow for the purposes of this diagnostic code.