summaryrefslogtreecommitdiffstats
path: root/tests/ui/consts/const-block-non-item-statement-3.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ui/consts/const-block-non-item-statement-3.rs')
-rw-r--r--tests/ui/consts/const-block-non-item-statement-3.rs8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/ui/consts/const-block-non-item-statement-3.rs b/tests/ui/consts/const-block-non-item-statement-3.rs
new file mode 100644
index 000000000..c513946d1
--- /dev/null
+++ b/tests/ui/consts/const-block-non-item-statement-3.rs
@@ -0,0 +1,8 @@
+// run-pass
+#![allow(dead_code, unused)]
+
+type Array = [u32; { let x = 2; 5 }];
+
+pub fn main() {
+ let _: Array = [0; 5];
+}