File tree
Expand file treeCollapse file tree2 files changed
+7
-2
lines changed Expand file treeCollapse file tree2 files changed
+7
-2
lines changed Original file line number | Diff line number | Diff line change |
---|
|
755 | 755 | (iterate (core/fn [[p b]]
|
756 | 756 | (if (core/== 2147483648 b)
|
757 | 757 | [(core/inc p) 1]
|
758 |
| -[p (core/bit-shift-left b 1)])) |
| 758 | +[p #?(:clj (core/bit-shift-left b 1) |
| 759 | +:cljs (core/* 2 b))])) |
759 | 760 | [0 1])))
|
760 | 761 |
|
761 | 762 | (def fast-path-protocol-partitions-count
|
|
Original file line number | Diff line number | Diff line change |
---|
|
1899 | 1899 | (defrecord C [a b c])
|
1900 | 1900 | (defrecord A' [x])
|
1901 | 1901 | (defrecord B' [x])
|
| 1902 | +(defrecord FooComparable [x] |
| 1903 | +IComparable |
| 1904 | +(-compare [_ o] (compare x (.-x o)))) |
1902 | 1905 |
|
1903 | 1906 | (deftest test-records
|
1904 | 1907 | (let [fred (Person. "Fred" "Mertz")
|
|
1939 | 1942 | (is (= (set (keys (dissoc more-letters :d))) #{:a :b :c :e :f}))
|
1940 | 1943 | (is (= (set (keys (dissoc more-letters :d :e))) #{:a :b :c :f}))
|
1941 | 1944 | (is (= (set (keys (dissoc more-letters :d :e :f))) #{:a :b :c}))
|
1942 |
| -(is (not= (A'. nil) (B'. nil)))))) |
| 1945 | +(is (not= (A'. nil) (B'. nil))) |
| 1946 | +(is (satisfies? IComparable (->FooComparable 1)))))) |
1943 | 1947 |
|
1944 | 1948 | (deftype FnLike []
|
1945 | 1949 | IFn
|
|
You can’t perform that action at this time.
0 commit comments