diff options
Diffstat (limited to 'ruby/step1_read_print.rb')
| -rw-r--r-- | ruby/step1_read_print.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/ruby/step1_read_print.rb b/ruby/step1_read_print.rb index 617323e..ded992a 100644 --- a/ruby/step1_read_print.rb +++ b/ruby/step1_read_print.rb @@ -24,10 +24,12 @@ def REP(str) return PRINT(EVAL(READ(str), {})) end +# repl loop while line = _readline("user> ") begin puts REP(line) rescue Exception => e - puts "Error: %{e}" + puts "Error: #{e}" + puts "\t#{e.backtrace.join("\n\t")}" end end |
