about summary refs log tree commit diff
path: root/tests/ui/array-slice-vec/suggest-array-length.fixed
diff options
context:
space:
mode:
authorTshepang Mbambo <hopsi@tuta.io>2025-06-19 22:14:30 +0200
committerGitHub <noreply@github.com>2025-06-19 22:14:30 +0200
commit6ad42bf4e7ab81ec3d66a5e47dfe01dc51603c0b (patch)
tree59d2cbb81c6cf1bb95feb51963d037fd67fc51bf /tests/ui/array-slice-vec/suggest-array-length.fixed
parentf25cfe83f2a13d96731861caae7236372f6445d5 (diff)
parentd854d563445082268ca8e7dd76b6ccde0342c2b3 (diff)
downloadrust-6ad42bf4e7ab81ec3d66a5e47dfe01dc51603c0b.tar.gz
rust-6ad42bf4e7ab81ec3d66a5e47dfe01dc51603c0b.zip
Merge pull request #2477 from rust-lang/rustc-pull
Rustc pull update
Diffstat (limited to 'tests/ui/array-slice-vec/suggest-array-length.fixed')
-rw-r--r--tests/ui/array-slice-vec/suggest-array-length.fixed15
1 files changed, 5 insertions, 10 deletions
diff --git a/tests/ui/array-slice-vec/suggest-array-length.fixed b/tests/ui/array-slice-vec/suggest-array-length.fixed
index 2eacc2517d3..ae1c6583c23 100644
--- a/tests/ui/array-slice-vec/suggest-array-length.fixed
+++ b/tests/ui/array-slice-vec/suggest-array-length.fixed
@@ -10,14 +10,9 @@ fn main() {
     //~^ ERROR the placeholder `_` is not allowed within types on item signatures for static variables
     static REF_STATIK: &[u8; 1] = &[1];
     //~^ ERROR the placeholder `_` is not allowed within types on item signatures for static variables
-    let foo: [i32; 3] = [1, 2, 3];
-    //~^ ERROR using `_` for array lengths is unstable
-    let bar: [i32; 3] = [0; 3];
-    //~^ ERROR using `_` for array lengths is unstable
-    let ref_foo: &[i32; 3] = &[1, 2, 3];
-    //~^ ERROR using `_` for array lengths is unstable
-    let ref_bar: &[i32; 3] = &[0; 3];
-    //~^ ERROR using `_` for array lengths is unstable
-    let multiple_ref_foo: &&[i32; 3] = &&[1, 2, 3];
-    //~^ ERROR using `_` for array lengths is unstable
+    let foo: [i32; _] = [1, 2, 3];
+    let bar: [i32; _] = [0; 3];
+    let ref_foo: &[i32; _] = &[1, 2, 3];
+    let ref_bar: &[i32; _] = &[0; 3];
+    let multiple_ref_foo: &&[i32; _] = &&[1, 2, 3];
 }