I have a ptr_map as follows:
typedef boost::ptr_map TextureContainer;
I only use forward declarations of Texture where needed. When I'm iterating
over an instance of TextureContainer, I expect to not have to do more than
use the forward declaration since technically we're only iterating pointer
values and the definition of Texture is not needed for this. So when I do
this:
TextureContainer myTextures;
TextureContainer::const_iterator it = myTextures.find( "some key" );
The above (second line) results in an extremely complex and long compiler
error, but the important part of the error says what I have pasted below.
Why is this error happening? Is it trying to clone Texture objects? This
shouldn't be happening.
*boost/ptr_container/clone_allocator.hpp(34) : error C2514: 'rs::Texture' :
class has no constructors
C:\IT\work\planb\components\rs/renderer/TextureFwd.hpp(6) : see
declaration of 'rs::Texture'
C:\IT\work\planb\third_party\boost\1_37_0\boost/ptr_container/clone_allocator.hpp(55)
: see reference to function template instantiation 'T
*boost::new_clone<U>(const T &)' being compiled*