> I think you misread the source of fnmap. Of course it creates a new
> map in the beginning just as hash-map does. Then assoc/dissoc/etc.
> just delegates to the underlying map with the appropriate fiddling
> with the setter/getter.
>
> If you already have a map you can do something like:
>
> (require '[clojure.contrib.fnmap.PersistentMap :as fnmap])
>
> (defn to-fnmap
>  [the-map setter getter]
>  (clojure.contrib.fnmap.PersistentFnMap. (assoc the-map ::fnmap/
> setter setter ::fnamp/getter getter)))

I didn't read the code as thoroughly as you did. Thanks for pointing
out this approach. It would make a nice addition to the exposed API.



-- 
Florian Ebeling
florian.ebel...@gmail.com
-- 
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

Reply via email to