Added erase function for easier semantics and readability