> I'm curious why hash-map uses a form to createWithCheck, and hash-set
> uses a static method.
They both use a static method, though hash-set uses the newer
idiomatic syntax.
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, sen
On 3 May 2010 16:13, Sean Devlin wrote:
> These two fns are right next to each other in core:
>
> (defn hash-map
> "keyval => key val
> Returns a new hash map with supplied mappings."
> ([] {})
> ([& keyvals]
> (. clojure.lang.PersistentHashMap (createWithCheck keyvals
>
> (defn hash-set
These two fns are right next to each other in core:
(defn hash-map
"keyval => key val
Returns a new hash map with supplied mappings."
([] {})
([& keyvals]
(. clojure.lang.PersistentHashMap (createWithCheck keyvals
(defn hash-set
"Returns a new hash set with supplied keys."
([]