Re: Records implementing IFn

2011-02-08 Thread Mark Fredrickson
Thank you. That seems to do the trick. -Mark On Feb 7, 11:55 pm, Alex Osborne wrote: > Mark Fredrickson writes: > > Is the following behavior correct or a bug: > > > user> (defrecord Example [data] clojure.lang.IFn (invoke [this] this) > > (invoke [this n] (repeat n this))) > > user.Example >

Re: Records implementing IFn

2011-02-07 Thread Alex Osborne
Mark Fredrickson writes: > Is the following behavior correct or a bug: > > user> (defrecord Example [data] clojure.lang.IFn (invoke [this] this) > (invoke [this n] (repeat n this))) > user.Example > user> (def e (Example. "I am e")) > #'user/e > user> (e 2) > (#:user.Example{:data "I am e"} #:use

Records implementing IFn

2011-02-07 Thread Mark Fredrickson
Is the following behavior correct or a bug: user> (defrecord Example [data] clojure.lang.IFn (invoke [this] this) (invoke [this n] (repeat n this))) user.Example user> (def e (Example. "I am e")) #'user/e user> e #:user.Example{:data "I am e"} user> (e 2) (#:user.Example{:data "I am e"} #:user.Exa