We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 96258a5 commit d72c13dCopy full SHA for d72c13d
[refs]
@@ -1,5 +1,5 @@
1
---
2
-refs/heads/master: 55752a4bdeae5dad77875b7702a14882fd12725b
+refs/heads/master: 75c6428e1bf2f5564392276642d962163d8a9809
3
refs/heads/snap-stage3: 1af31d4974e33027a68126fa5a5a3c2c6491824f
4
refs/heads/try: b53c0f93eedcdedd4fd89bccc5a3a09d1c5cd23e
5
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
trunk/src/librustc_borrowck/diagnostics.rs
@@ -179,6 +179,14 @@ let mut x: i64 = 1;
179
let mut y: Box<_> = Box::new(&mut x);
180
**y = 2;
181
```
182
+
183
+It can also be fixed by using a type with interior mutability, such as `Cell` or
184
+`RefCell`:
185
186
+```
187
+let y: Cell<_> = Cell::new(1);
188
+y.set(2);
189
190
"##,
191
192
E0387: r##"
0 commit comments