about summary refs log tree commit diff
path: root/src/lib/vec.rs
diff options
context:
space:
mode:
authorMarijn Haverbeke <marijnh@gmail.com>2011-06-02 16:45:26 +0200
committerMarijn Haverbeke <marijnh@gmail.com>2011-06-02 16:45:26 +0200
commit5144f790fe7c57224ba164ca0ecc81cfcc4ddd20 (patch)
treee728d419107cba6225e046d6150836f40fb8fe83 /src/lib/vec.rs
parent75ffe657dbd202cf22175f0234e80f4e09c5d499 (diff)
downloadrust-5144f790fe7c57224ba164ca0ecc81cfcc4ddd20.tar.gz
rust-5144f790fe7c57224ba164ca0ecc81cfcc4ddd20.zip
Fix and un-xfail vec-append test
Diffstat (limited to 'src/lib/vec.rs')
-rw-r--r--src/lib/vec.rs5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/lib/vec.rs b/src/lib/vec.rs
index 3815031b305..969fca9a17e 100644
--- a/src/lib/vec.rs
+++ b/src/lib/vec.rs
@@ -50,8 +50,9 @@ fn refcount[T](array[T] v) -> uint {
     if (r == dbg::const_refcount) {
         ret r;
     } else {
-        // -1 because calling this function incremented the refcount.
-        ret  r - 1u;
+        // -2 because calling this function and the native function both
+        // incremented the refcount.
+        ret  r - 2u;
     }
 }