diff options
Diffstat (limited to 'ruby/step9_try.rb')
| -rw-r--r-- | ruby/step9_try.rb | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/ruby/step9_try.rb b/ruby/step9_try.rb index eecba9c..74d0f59 100644 --- a/ruby/step9_try.rb +++ b/ruby/step9_try.rb @@ -155,7 +155,6 @@ repl_env.set(:eval, lambda {|ast| EVAL(ast, repl_env)}) repl_env.set(:"*ARGV*", List.new(ARGV.slice(1,ARGV.length) || [])) # core.mal: defined using the language itself -RE["(def! *host-language* \"ruby\")"] RE["(def! not (fn* (a) (if a false true)))"] RE["(def! load-file (fn* (f) (eval (read-string (str \"(do \" (slurp f) \")\")))))"] RE["(defmacro! cond (fn* (& xs) (if (> (count xs) 0) (list 'if (first xs) (if (> (count xs) 1) (nth xs 1) (throw \"odd number of forms to cond\")) (cons 'cond (rest (rest xs)))))))"] @@ -167,7 +166,6 @@ if ARGV.size > 0 end # repl loop -RE["(println (str \"Mal [\" *host-language* \"]\"))"] while line = _readline("user> ") begin puts REP[line] |
