Boost logo

Boost :

From: Beman Dawes (bdawes_at_[hidden])
Date: 2002-06-17 15:36:18

I think that dyn_bitset should be accepted.


* As others have mentioned, the name is too cryptic, and should be changed
to "dynamic_bitset" or similar. (I don't like "bit_vector" because the
name leads me to expect an interface like vector<bool>.)

* Why is there an append(Block) and an append(Block iterator range) but no
append( dyn_bitset )? Seems like that would be useful, and is tricky to get
right when size() isn't a multiple of sizeof(Block). It might have to be a
member template to handle type conversion issues.

* In the resize() specification, it isn't clear to me what "discarded"
means in "If num_bits < size() then the bits in the range [0,num_bits) stay
the same (and the remaining bits are discarded)." Is there a
"shrink-to-fit" reallocation, or does the memory remain allocated and the
discarded bits simply ignored?

* Shouldn't the dyn_bitset(size_type num_bits, unsigned long value = 0,
const Allocator& alloc = Allocator()) constructor be made explicit?

* The documentation should begin with a little table of contents. See or for examples.

Caveat: I've only looked at the documentation, and have not tried to
actually use the code.


Boost list run by bdawes at, gregod at, cpdaniel at, john at