1 USING: help.markup help.syntax sequences ;
4 ARTICLE: "bit-vectors" "Bit vectors"
5 "A bit vector is a resizable mutable sequence of bits. Bit vector words are found in the " { $vocab-link "bit-vectors" } " vocabulary."
7 "Bit vectors form a class:"
12 "Creating bit vectors:"
18 { $subsections POSTPONE: ?V{ }
19 "If you don't care about initial capacity, a more elegant way to create a new bit vector is to write:"
20 { $code "?V{ } clone" } ;
25 { $description "The class of resizable bit vectors. See " { $link "bit-vectors" } " for information." } ;
28 { $values { "capacity" "a positive integer specifying initial capacity" } { "vector" bit-vector } }
29 { $description "Creates a new bit vector that can hold " { $snippet "n" } " bits before resizing." } ;
32 { $values { "seq" sequence } { "vector" bit-vector } }
33 { $description "Outputs a freshly-allocated bit vector with the same elements as a given sequence." } ;
36 { $syntax "?V{ elements... }" }
37 { $values { "elements" "a list of booleans" } }
38 { $description "Marks the beginning of a literal bit vector. Literal bit vectors are terminated by " { $link POSTPONE: } } "." }
39 { $examples { $code "?V{ t f t }" } } ;