]> git.lizzy.rs Git - rust.git/blobdiff - src/test/ui/parenthesised-deref-suggestion.rs
Rollup merge of #57107 - mjbshaw:thread_local_test, r=nikomatsakis
[rust.git] / src / test / ui / parenthesised-deref-suggestion.rs
index bcbb51ccd6b655a7c834119a14a178fe508edfbb..0b4ccdd5a56d4939ce553c2bc25bd6f717558479 100644 (file)
@@ -5,4 +5,7 @@ struct Session {
 fn main() {
     let sess: &Session = &Session { opts: 0 };
     (sess as *const Session).opts; //~ ERROR no field `opts` on type `*const Session`
+
+    let x = [0u32];
+    (x as [u32; 1]).0; //~ ERROR no field `0` on type `[u32; 1]`
 }