1
0
Fork 0

Missed delete in ex7.4 Stack

This commit is contained in:
Eric Teunis de Boone 2020-01-10 16:21:10 +01:00
parent d9d2d5f18f
commit e363d023cd

View file

@ -11,6 +11,9 @@ class Stack {
Stack() {
_s = new std::deque<T>();
}
~Stack() {
delete _s;
}
int nitems() { return _s->size() ; }
bool empty() { return (_s->size() == 0) ; }