From 3175c83ff0b374326d959ba0731991175466e745 Mon Sep 17 00:00:00 2001 From: Graydon Hoare Date: Mon, 5 Jul 2010 14:43:02 -0700 Subject: [PATCH] Un-XFAIL mutable-alias-vec.rs. Was only failing due to a typo, but a more thorough test revealed more bugs. --- src/Makefile | 1 - src/test/run-pass/mutable-alias-vec.rs | 14 ++++++++++++-- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/src/Makefile b/src/Makefile index bed03b49c39..d0b9652c39d 100644 --- a/src/Makefile +++ b/src/Makefile @@ -345,7 +345,6 @@ TEST_XFAILS_X86 := $(MUT_BOX_XFAILS) \ test/run-pass/generic-fn-infer.rs \ test/run-pass/generic-fn-twice.rs \ test/run-pass/generic-recursive-tag.rs \ - test/run-pass/mutable-alias-vec.rs \ test/run-pass/mutable-vec-drop.rs \ test/run-pass/bind-obj-ctor.rs \ test/run-pass/task-comm.rs \ diff --git a/src/test/run-pass/mutable-alias-vec.rs b/src/test/run-pass/mutable-alias-vec.rs index 7e22740cd9c..004b683aa44 100644 --- a/src/test/run-pass/mutable-alias-vec.rs +++ b/src/test/run-pass/mutable-alias-vec.rs @@ -1,7 +1,17 @@ // -*- rust -*- -fn grow(mutable &vec[int] v) { +use std; + +fn grow(&mutable vec[int] v) { v += vec(1); } -fn main() {} +fn main() { + let vec[int] v = vec(); + grow(v); + grow(v); + grow(v); + auto len = std._vec.len[int](v); + log len; + check (len == uint(3)); +}