From 718887c3019c49fc807bc18fbd5feb975ec03c85 Mon Sep 17 00:00:00 2001 From: Joel Martin Date: Thu, 17 Apr 2014 22:23:07 -0500 Subject: Ruby,Python,C#: readline history fixes. Ruby include path. --- ruby/step5_tco.rb | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'ruby/step5_tco.rb') diff --git a/ruby/step5_tco.rb b/ruby/step5_tco.rb index c6b5782..e2fe5e7 100644 --- a/ruby/step5_tco.rb +++ b/ruby/step5_tco.rb @@ -1,4 +1,5 @@ -require "readline" +$: << File.expand_path(File.dirname(__FILE__)) +require "mal_readline" require "types" require "reader" require "printer" @@ -94,7 +95,7 @@ repl_env.set(:eval, lambda {|ast| EVAL(ast, repl_env)}) # core.mal: defined using the language itself RE["(def! not (fn* (a) (if a false true)))"] -while line = Readline.readline("user> ", true) +while line = _readline("user> ") begin puts REP[line] rescue Exception => e -- cgit v1.2.3