hi,
template <class T>
class MyStack
{
stack<T *> m_Stack;
public:
void myPop()
{
T* ptr = m_Stack.top();
delete ptr; // assertion error, block still in used??
m_Stack.pop();
}
};
i used this class this way..,
MyStack.myPush(new Object());
help? many thanks!
EDIT: actually this thing works if i don't encapulsulate std::stack into another class,