@calcit/ternary-tree 0.0.19 → 0.0.20
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/list.mjs +2 -2
- package/package.json +1 -1
- package/lib/index.html +0 -2
package/lib/list.mjs
CHANGED
@@ -91,10 +91,10 @@ export function initTernaryTreeList(xs) {
|
|
91
91
|
}
|
92
92
|
// from a slice of an existed array
|
93
93
|
export function initTernaryTreeListFromRange(xs, from, to) {
|
94
|
-
let ys = new Array(
|
94
|
+
let ys = new Array(to - from);
|
95
95
|
for (let idx = from; idx < to; idx++) {
|
96
96
|
let x = xs[idx];
|
97
|
-
ys[idx] = { kind: TernaryTreeKind.ternaryTreeLeaf, size: 1, value: x };
|
97
|
+
ys[idx - from] = { kind: TernaryTreeKind.ternaryTreeLeaf, size: 1, value: x };
|
98
98
|
}
|
99
99
|
return makeTernaryTreeList(xs.length, 0, ys);
|
100
100
|
}
|
package/package.json
CHANGED
package/lib/index.html
DELETED