src/bitvector.c
/*  Print the elements of a bit vector that are TRUE.  The bitprint argument
    specifies a function to print a single bit.  This allows you to print
    sensible output when the bits represent something other than integers.
    The fprint_bit function may be used to print them as integers.  */
Print the elements of a bit vector that are TRUE.  The bitprint argument
specifies a function to print a single bit.  This allows you to print
sensible output when the bits represent something other than integers.
The fprint_bit function may be used to print them as integers.
Print the elements of a bit vector that are TRUE . The bitprint argument specifies a function to print a single bit . This allows you to print sensible output when the bits represent something other than integers . The fprint_bit function may be used to print them as integers .
void
fprint_bits (FILE *fd, bit_vector *b, bitprint_f bitprint)
{
    int i;
    for (i = 0; i < b->num_bits; i++) {
        if (get_bit(b, i)) {
            fputc(' ', fd);
            bitprint(fd, i);
        }
    }
}
void fprint_bits ( FILE * fd , bit_vector * b , bitprint_f bitprint ) { int i ; for ( i = 0 ; i < b -> num_bits ; i ++ ) { if ( get_bit ( b , i ) ) { fputc ( ' ' , fd ) ; bitprint ( fd , i ) ; } } }
Print the elements of a bit vector that are TRUE.
Print the elements of a bit vector that are TRUE .