Heya
I've got the following :
enum Type
{ One = 0, Two};
class MySubClass
{
private:
MySubClass(); // prohibited
MySubClass(const MySubClass&); // prohibited
MySubClass & operator (const MySubClass&); // prohibited
public :
MySubClass(int x);
};
class MyClass
{
MyClass(int x) : m_x(new SubClass(x))
{}
~MyClass()
{ delete m_x; }
private :
MySubClass * m_x;
};
typedef multimap<Type, MyClass> my_multimap;
typedef pair<Type, MyClass> my_pair;
I'm trying to do the following :
my_multimap my_map;
my_map.insert(my_pair(One, MyClass(5)));
And I'm getting an unhandled exception result, the app is trying to read 0xfeeefeee etc.
What's going on? How can I fix this? Please note that this is a simplified case of what I'm dealing with;