diff --git a/AK/Vector.h b/AK/Vector.h index 76c96d05b8d..012b23ae27b 100644 --- a/AK/Vector.h +++ b/AK/Vector.h @@ -263,6 +263,13 @@ public: return value; } + T take(int index) + { + T value = move(at(index)); + remove(index); + return value; + } + void remove(int index) { ASSERT(index < m_size);