From 6c056fba4db7bd85a5fb3610bec6c00a7ad64f81 Mon Sep 17 00:00:00 2001 From: Niko Matsakis Date: Thu, 14 Jun 2012 16:27:44 -0700 Subject: [PATCH] random forgotten test case --- src/test/run-pass/borrowck-fixed-length-vecs.rs | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 src/test/run-pass/borrowck-fixed-length-vecs.rs diff --git a/src/test/run-pass/borrowck-fixed-length-vecs.rs b/src/test/run-pass/borrowck-fixed-length-vecs.rs new file mode 100644 index 00000000000..538d1f4c521 --- /dev/null +++ b/src/test/run-pass/borrowck-fixed-length-vecs.rs @@ -0,0 +1,8 @@ +// xfail-fast (compile-flags unsupported on windows) +// compile-flags:--borrowck=err + +fn main() { + let x = [22]/1; + let y = &x[0]; + assert *y == 22; +} \ No newline at end of file