Commit 00ee8ae
committed
fix: off-by-one in runContainer16.getCardinalityInRange for intra-container gaps
When the query range falls entirely in a gap between two run intervals
within the same container, the early-return guard "lastIdx < firstIdx-1"
misses the case where lastIdx == firstIdx-1, causing the next interval
(outside the query range) to be counted.
Fix: change the condition to "lastIdx < firstIdx".1 parent fcd24ee commit 00ee8ae
1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2543 | 2543 | | |
2544 | 2544 | | |
2545 | 2545 | | |
2546 | | - | |
| 2546 | + | |
2547 | 2547 | | |
2548 | 2548 | | |
2549 | 2549 | | |
| |||
0 commit comments