Show functions in REPL

Fixes #3
Correctly handle undefined return values in the REPL

Fixes #4