Implement pop_back() and clear().