On 22 May 2010 04:03, Ben Mabey <[email protected]> wrote:
> How about merging?
>
> user=> (merge (Bar. {}) m)
> #:user.Bar{:x 1, :y 2}
>
> This approach at least doesn't require that you know in advance the keys of
> Bar.

No, you still do:

user=> (defrecord Foo [x y z])
user.Foo
user=> (merge (Foo. {}) m)
No matching ctor found for class user.Foo

But that's okay; I'm just going to have to use constructor function
instead of a raw type.

- James

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to [email protected]
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Reply via email to