So, the documentation says this:
template <typename Char, typename Traits, typename Block, typename Alloc>
basic_ostream<Char, Traits>&
operator<<(basic_ostream<Char, Traits>& os, const dynamic_bitset<Block, Alloc>& b)
Effects: Inserts a textual representation of b into the stream os (highest bit first). Informally, the output is the same as doing
std::basic_string<Char, Traits> s;
boost::to_string(x, s):
os << s;
which I don't understand at all.
Here is what I have
boost::dynamic_bitset<> bit_value(Config::HASH_WIDTH_IN_BITS, hash_value);
string buffer = bit_value.to_string();
Which doesn't work, cause dynamic bitset has no member .to_string();