Mercurial > rlm
annotate src/rlm/println.clj @ 9:1065e7d615a4 tip
deactivate some cruft.
author | Robert McIntyre <rlm@mit.edu> |
---|---|
date | Mon, 08 Jul 2013 12:51:12 -0400 |
parents | 78a630e650d2 |
children |
rev | line source |
---|---|
rlm@0 | 1 (ns rlm.println) |
rlm@0 | 2 |
rlm@0 | 3 |
rlm@0 | 4 (def println-repl (bound-fn [& args] (apply println args))) |
rlm@0 | 5 |
rlm@0 | 6 |
rlm@0 | 7 |
rlm@0 | 8 (defn println-terminal [& more] |
rlm@0 | 9 (.println System/out (apply str more))) |
rlm@0 | 10 |
rlm@0 | 11 |
rlm@0 | 12 (defmacro print-to-repl [& forms] |
rlm@0 | 13 `(binding [clojure.core/*out* |
rlm@0 | 14 (java.io.PrintWriter. (clojure.java.io/writer System/out))] |
rlm@0 | 15 ~@forms)) |
rlm@0 | 16 |