diff --git a/basis/vectors/functor/functor.factor b/basis/vectors/functor/functor.factor index b70c7c5050..a2a67d58bc 100644 --- a/basis/vectors/functor/functor.factor +++ b/basis/vectors/functor/functor.factor @@ -24,6 +24,8 @@ M: V new-sequence drop [ ] [ >fixnum ] bi V boa ; inline M: A new-resizable drop ; inline +M: V new-resizable drop ; inline + M: V equal? over V instance? [ sequence= ] [ 2drop f ] if ; : >V ( seq -- vector ) V new clone-like ; inline diff --git a/core/byte-vectors/byte-vectors.factor b/core/byte-vectors/byte-vectors.factor index 287e972405..4f6ade8580 100644 --- a/core/byte-vectors/byte-vectors.factor +++ b/core/byte-vectors/byte-vectors.factor @@ -43,4 +43,6 @@ M: byte-array like M: byte-array new-resizable drop ; inline +M: byte-vector new-resizable drop ; inline + INSTANCE: byte-vector growable diff --git a/core/growable/growable.factor b/core/growable/growable.factor index 68a8de3d43..2ca11e2e24 100644 --- a/core/growable/growable.factor +++ b/core/growable/growable.factor @@ -66,4 +66,6 @@ M: growable shorten ( n seq -- ) 2dup (>>length) ] when 2drop ; inline +M: growable new-resizable new-sequence 0 over set-length ; inline + INSTANCE: growable sequence diff --git a/core/sbufs/sbufs.factor b/core/sbufs/sbufs.factor index 49b6ec1374..db2649142d 100644 --- a/core/sbufs/sbufs.factor +++ b/core/sbufs/sbufs.factor @@ -23,13 +23,13 @@ M: sbuf like dup string? [ dup length sbuf boa ] [ >sbuf ] if ] unless ; inline -M: sbuf new-resizable drop ; inline - M: sbuf equal? over sbuf? [ sequence= ] [ 2drop f ] if ; M: string new-resizable drop ; inline +M: sbuf new-resizable drop ; inline + M: string like #! If we have a string, we're done. #! If we have an sbuf, and it's at full capacity, we're done.