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 b06247b commit 3373567Copy full SHA for 3373567
src/main/cljs/cljs/core.cljs
@@ -1574,11 +1574,11 @@ reduces them without incurring seq initialization"
1574
1575
(array? o)
1576
(when (< k (.-length o))
1577
- (aget o k))
+ (aget o (int k)))
1578
1579
(string? o)
1580
1581
1582
1583
(native-satisfies? ILookup o)
1584
(-lookup o k)
src/test/cljs/cljs/core_test.cljs
@@ -2829,6 +2829,9 @@
2829
(is (= (reduce my-conj [] (eduction (map identity) [1 2 3]))
2830
[1 2 3])))
2831
2832
+(deftest test-get-string-float
2833
+ (is (= (get "hi" 1.7) \i)))
2834
+
2835
(comment
2836
;; ObjMap
2837
;; (let [ks (map (partial str "foo") (range 500))
0 commit comments