Skip to content
  • Thomas Haller's avatar
    utils: extend binary-search to return the first/last index · d83eee5d
    Thomas Haller authored
    binary-search can find an index of a matching entry in a sorted
    list. However, if the list contains multiple entries that compare
    equal, it can be interesting to find the first/last entry. For example,
    if you want to append new items after the last.
    
    Extend binary search to optionally continue the binary search
    to determine the range that compares equal.
    d83eee5d