diff options
Diffstat (limited to 'tests/ui/consts/const-expr-in-fixed-length-vec.rs')
-rw-r--r-- | tests/ui/consts/const-expr-in-fixed-length-vec.rs | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/ui/consts/const-expr-in-fixed-length-vec.rs b/tests/ui/consts/const-expr-in-fixed-length-vec.rs new file mode 100644 index 000000000..a9960b455 --- /dev/null +++ b/tests/ui/consts/const-expr-in-fixed-length-vec.rs @@ -0,0 +1,12 @@ +// run-pass +// Check that constant expressions can be used for declaring the +// type of a fixed length vector. + +// pretty-expanded FIXME #23616 + +pub fn main() { + + const FOO: usize = 2; + let _v: [isize; FOO*3]; + +} |