|
insert
Syntax:
#include <boost/bit_logic/bit_vector.hpp> iterator insert ( iterator loc , bool val ) ; void insert ( iterator loc, std::size_t num, bool val ) ; std::size_t insert ( std::size_t insert_idx , BitTypeT const & insert_val ) ; The insert() function inserts data into a bit_vector at a given location, shifting any bits above that location up to accomodate the size of the inserted data. bit_vector<> v ( 4 ) ; bit_array<4> a ; a = "1111" ; v.insert ( v.size(), a ) ; cout << hex << v ; This code produces the following output: f0 Exceptions:
|