diff options
| author | bors <bors@rust-lang.org> | 2023-05-31 19:26:05 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2023-05-31 19:26:05 +0000 |
| commit | 90c541806f23a127002de5b4038be731ba1458ca (patch) | |
| tree | d3e039dc1ad5b4c1e151ee6af36cd76b61e46330 /compiler/rustc_middle/src/mir/syntax.rs | |
| parent | d332def19cf07973b736d0c7eb1b690d7c9d945e (diff) | |
| parent | 4930c02c008211f06482fef848dbf5d459475efb (diff) | |
| download | rust-1.70.0.tar.gz rust-1.70.0.zip | |
Auto merge of #112145 - wesleywiser:backport_112070, r=Mark-Simulacrum 1.70.0
Backport of #112070 Backports #112070 to stable r? `@Mark-Simulacrum`
Diffstat (limited to 'compiler/rustc_middle/src/mir/syntax.rs')
| -rw-r--r-- | compiler/rustc_middle/src/mir/syntax.rs | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/compiler/rustc_middle/src/mir/syntax.rs b/compiler/rustc_middle/src/mir/syntax.rs index 135889d0da8..93800d48407 100644 --- a/compiler/rustc_middle/src/mir/syntax.rs +++ b/compiler/rustc_middle/src/mir/syntax.rs @@ -220,6 +220,11 @@ pub enum BorrowKind { /// immutable, but not aliasable. This solves the problem. For /// simplicity, we don't give users the way to express this /// borrow, it's just used when translating closures. + /// + // FIXME(#112072): This is wrong. Unique borrows are mutable borrows except + // that they do not require their pointee to be marked as a mutable. + // They should still be treated as mutable borrows in every other way, + // e.g. for variance or overlap checking. Unique, /// Data is mutable and not aliasable. |
