about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorDonough Liu <ldm2993593805@163.com>2020-05-01 21:57:19 +0800
committerDonough Liu <ldm2993593805@163.com>2020-05-02 12:04:03 +0800
commit089d4bbfd79c4ae2e735154cff4448ecd5fc4afc (patch)
tree74383c7f133608d828f70fb26304f17206cf3a95 /src
parent80d04cc1ba610d796c84427622ce17eb2ca9c771 (diff)
downloadrust-089d4bbfd79c4ae2e735154cff4448ecd5fc4afc.tar.gz
rust-089d4bbfd79c4ae2e735154cff4448ecd5fc4afc.zip
Suggestion for immutable reference -> mutable pointer should be emitted
as `Applicability::Unspecified`
Diffstat (limited to 'src')
-rw-r--r--src/test/ui/issues/issue-71676-2.rs1
-rw-r--r--src/test/ui/issues/issue-71676-2.stderr2
2 files changed, 1 insertions, 2 deletions
diff --git a/src/test/ui/issues/issue-71676-2.rs b/src/test/ui/issues/issue-71676-2.rs
index d11fce567ce..f3183899dc5 100644
--- a/src/test/ui/issues/issue-71676-2.rs
+++ b/src/test/ui/issues/issue-71676-2.rs
@@ -37,7 +37,6 @@ impl DerefMut for Emm {
     }
 }
 fn main() {
-    // Should not suggest when a is immutable
     let a = Emm(Foo(Bar(0)));
     let _: *mut u8 = &a; //~ ERROR mismatched types
 }
diff --git a/src/test/ui/issues/issue-71676-2.stderr b/src/test/ui/issues/issue-71676-2.stderr
index 273ae9cb4db..ebdd345809a 100644
--- a/src/test/ui/issues/issue-71676-2.stderr
+++ b/src/test/ui/issues/issue-71676-2.stderr
@@ -1,5 +1,5 @@
 error[E0308]: mismatched types
-  --> $DIR/issue-71676-2.rs:42:22
+  --> $DIR/issue-71676-2.rs:41:22
    |
 LL |     let _: *mut u8 = &a;
    |            -------   ^^