Skip to content

Commit

Permalink
add comment for removing zeros
Browse files Browse the repository at this point in the history
  • Loading branch information
euroelessar committed Dec 17, 2024
1 parent 394b85a commit 8f73157
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ func Merge(arel, brel Buckets) {

lo := min(a.Lower(), b.Lower())
up := max(a.Upper(), b.Upper())

// Skip leading and trailing zeros to reduce number of buckets.
// As we cap number of buckets this allows us to have higher scale.
for lo < up && a.Abs(lo) == 0 && b.Abs(lo) == 0 {
lo++
}
Expand Down

0 comments on commit 8f73157

Please sign in to comment.