to be consistent, we should be converting keys this way here too
This commit is contained in:
parent
ce93336731
commit
f2a864b2e1
|
@ -15,9 +15,7 @@
|
|||
(.entrySet)
|
||||
(reduce
|
||||
(fn [m [k v]]
|
||||
; TODO: perhaps we should be doing (keyword k) instead? i don't like that it technically is not an
|
||||
; exact conversion if we do it that way though, even if it is more idiomatic for clojure ...
|
||||
(assoc m k (to-clojure v)))
|
||||
(assoc m (to-clojure k) (to-clojure v)))
|
||||
{})))
|
||||
|
||||
java.lang.Number
|
||||
|
@ -36,6 +34,10 @@
|
|||
(to-clojure [x]
|
||||
x)
|
||||
|
||||
clojure.lang.Keyword
|
||||
(to-clojure [x]
|
||||
x)
|
||||
|
||||
java.lang.Object
|
||||
(to-clojure [x]
|
||||
(-> x
|
||||
|
@ -80,4 +82,4 @@
|
|||
(defn clojure->java
|
||||
"converts a clojure value to an equivalent value using a java object"
|
||||
[x]
|
||||
(to-java x))
|
||||
(to-java x))
|
Reference in a new issue