fixes #4
Modify REPL to be able to exit with CTRL-D