]> git.lizzy.rs Git - rust.git/blobdiff - src/test/ui/borrowck/issue-91206.rs
Do not use a suggestion to change a binding's name to a type
[rust.git] / src / test / ui / borrowck / issue-91206.rs
index 3b1fbf4b69902828b695ec08fca20bdc6bac12c7..67407c1eae3cfe2bf2144e0e97609146d26de3b2 100644 (file)
@@ -9,7 +9,8 @@ fn get_inner_ref(&self) -> &Vec<usize> {
 fn main() {
     let client = TestClient;
     let inner = client.get_inner_ref();
-    //~^ HELP consider changing this to be a mutable reference
+    //~^ NOTE consider changing this binding's type to be
     inner.clear();
     //~^ ERROR cannot borrow `*inner` as mutable, as it is behind a `&` reference [E0596]
+    //~| NOTE `inner` is a `&` reference, so the data it refers to cannot be borrowed as mutable
 }