Implement #reset and #clear in the REPL