diff options
author | Rich Hickey <richhickey@gmail.com> | 2009-02-11 00:42:29 +0000 |
---|---|---|
committer | Rich Hickey <richhickey@gmail.com> | 2009-02-11 00:42:29 +0000 |
commit | be3d2c8c8702d76bdb091a9f2c17c293f3eceb5d (patch) | |
tree | bd2e4ae64b6f216fa898754e6a56982ab7b290ff | |
parent | 3d30e8c97631bdf5c7527cfac358d78addd7790a (diff) |
IDeref print method honors *print-level*, patch from Chouser
-rw-r--r-- | src/clj/clojure/core_print.clj | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/clj/clojure/core_print.clj b/src/clj/clojure/core_print.clj index 7cf92a33..999bcf8c 100644 --- a/src/clj/clojure/core_print.clj +++ b/src/clj/clojure/core_print.clj @@ -302,10 +302,9 @@ (.write w ")")) (defmethod print-method clojure.lang.IDeref [o #^Writer w] - (.write w (format "#<%s@%x: " - (.getSimpleName (class o)) - (System/identityHashCode o))) - (print-method @o w) - (.write w ">")) + (print-sequential (format "#<%s@%x: " + (.getSimpleName (class o)) + (System/identityHashCode o)) + pr-on, "", ">", (list @o), w)) (def #^{:private true} print-initialized true) |