implement solid move-range approach - tests not running

This commit is contained in:
Kevin Jahns
2022-05-05 13:03:59 +02:00
parent b2b7b8c280
commit 69b7f4bfb9
4 changed files with 103 additions and 71 deletions

View File

@@ -563,7 +563,7 @@ const arrayTransactions = [
return
}
const pos = prng.int32(gen, 0, yarray.length - 1)
const len = 1 // prng.int32(gen, 1, math.min(3, yarray.length - pos))
const len = 1 // prng.int32(gen, 1, math.min(3, yarray.length - pos)) @todo!
const _newPosAdj = prng.int32(gen, 0, yarray.length - len)
// make sure that we don't insert in-between the moved range
const newPos = _newPosAdj + (_newPosAdj > yarray.length - len ? len : 0)