From 243a97e8dd9db641c4f0301f31509d8688223eeb Mon Sep 17 00:00:00 2001 From: Joe Groff Date: Sun, 7 Feb 2010 15:24:29 -0800 Subject: [PATCH] specialized-vectors: fix byte-length to return byte-length of the vector rather than of its underlying capacity --- basis/specialized-vectors/specialized-vectors.factor | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/basis/specialized-vectors/specialized-vectors.factor b/basis/specialized-vectors/specialized-vectors.factor index 7fa47aa501..557ca25cd5 100644 --- a/basis/specialized-vectors/specialized-vectors.factor +++ b/basis/specialized-vectors/specialized-vectors.factor @@ -1,7 +1,7 @@ ! Copyright (C) 2008, 2009 Slava Pestov. ! See http://factorcode.org/license.txt for BSD license. USING: accessors alien.c-types alien.parser assocs -compiler.units functors growable kernel lexer namespaces parser +compiler.units functors growable kernel lexer math namespaces parser prettyprint.custom sequences specialized-arrays specialized-arrays.private strings vocabs vocabs.parser vocabs.generated fry make ; @@ -26,7 +26,7 @@ V A vectors.functor:define-vector M: V contract 2drop ; inline -M: V byte-length underlying>> byte-length ; inline +M: V byte-length length \ T heap-size * ; inline M: V pprint-delims drop \ V{ \ } ;