We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d975d25 commit 614d180Copy full SHA for 614d180
src/main/cljs/cljs/core.cljs
@@ -12336,6 +12336,21 @@ reduces them without incurring seq initialization"
12336
(.fromArray Vector (.-arr args) (not (array? (.-arr args))))
12337
(Vector. nil (into-array args) nil)))
12338
12339
+(defn simple-vec
12340
+ [coll]
12341
+ (cond
12342
+ (map-entry? coll)
12343
+ [(key coll) (val coll)]
12344
+
12345
+ (vector? coll)
12346
+ (with-meta coll nil)
12347
12348
+ (array? coll)
12349
+ (.fromArray Vector coll)
12350
12351
+ :else
12352
+ (into [] coll)))
12353
12354
; The keys field is an array of all keys of this map, in no particular
12355
; order. Any string, keyword, or symbol key is used as a property name
12356
; to store the value in strobj. If a key is assoc'ed when that same
0 commit comments