fix backspace bug in repl