Vladimir Bokov <bokov.v...@gmail.com> writes: > I really like that (pr some-hash-map) dumps structure which can be > recognized by clojure reader like (def same-hash-map '..paste..here) > > Could it be achieved with defrecords? Currently (pr some-record) produced > non-recognizable by clojure reader at all. (Btw. why so?)
What clojure version are you using? At least with 1.6.0 and onwards, record instances are printed readable. user=> (defrecord P [x y]) user.P user=> (->P 1 2) #user.P{:x 1, :y 2} user=> (read-string "#user.P{:x 1, :y 2}") #user.P{:x 1, :y 2} Bye, Tassilo -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups "Clojure" group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.