Boost C++ Libraries

...one of the most highly regarded and expertly designed C++ library projects in the world. Herb Sutter and Andrei Alexandrescu, C++ Coding Standards

This is the documentation for a snapshot of the develop branch, built from commit afebb7b30f.
PrevUpHomeNext

Known Issues

Move emulation limitations in C++03 compilers

Boost.Container uses Boost.Move to implement move semantics both in C++03 and C++11 compilers. However, as explained in Emulation limitations, there are some limitations in C++03 compilers that might surprise Boost.Container users.

The most noticeable problem is when Boost.Container containers are placed in a struct with a compiler-generated assignment operator:

class holder
{
   boost::container::vector<MyType> vect;
};

void func(const holder& h)
{
   holder copy_h(h); //<--- ERROR: can't convert 'const holder&' to 'holder&'
   //Compiler-generated copy constructor is non-const:
   // holder& operator(holder &)
   //!!!
}

This limitation forces the user to define a const version of the copy assignment, in all classes holding containers, which might be annoying in some cases.


PrevUpHomeNext