Search
View source code
Display the source code in dvec.d from which this page was generated on github.
Report a bug
Quickly fork, edit online, and submit a pull request for this page. Requires a signed-in GitHub account. This works well for small changes. If you'd like to make larger changes you may want to consider using local clone.

# Module `dvec`

Compiler implementation of the D programming language.

Simple bit vector implementation.

## Functions

NameDescription
``` vec_and(v1, v2, v3) ``` Compute v1 = v2 & v3.
``` vec_andass(v1, v2) ``` Compute v1 &= v2.
``` vec_calloc(numbits) ``` Allocate a vector given # of bits in it. Clear the vector.
``` vec_clear(v) ``` Clear vector.
``` vec_clearbit(b, v) ``` Clear bit b in vector v.
``` vec_clearextrabits(v) ``` Clear any extra bits in vector.
``` vec_clone(v) ``` Allocate copy of existing vector.
``` vec_copy(to, from) ``` Copy vector.
``` vec_disjoint(v1, v2) ``` Return 1 if (v1 & v2) == 0
``` vec_equal(v1, v2) ``` Return 1 if vectors are equal.
``` vec_free(v) ``` Free a vector.
``` vec_index(b, vec) ``` Find first set bit starting from b in vector v. If no bit is found, return vec_numbits(v).
``` vec_init() ``` Initialize package.
``` vec_or(v1, v2, v3) ``` Compute v1 = v2 | v3.
``` vec_orass(v1, v2) ``` Compute v1 |= v2.
``` vec_println(v) ``` Write out vector.
``` vec_realloc(v, numbits) ``` Realloc a vector to have numbits bits in it. Extra bits are set to 0.
``` vec_set(v) ``` Set vector.
``` vec_setbit(b, v) ``` Set bit b in vector v.
``` vec_sub(v1, v2, v3) ``` Compute v1 = v2 - v3.
``` vec_subass(v1, v2) ``` Compute v1 -= v2.
``` vec_term() ``` Terminate package.
``` vec_testbit(b, v) ``` Test bit b in vector v.
``` vec_xor(v1, v2, v3) ``` Compute v1 = v2 ^ v3.
``` vec_xorass(v1, v2) ``` Compute v1 ^= v2.