in BinSearch.equalOrMore and BinSearch.equalOrLess, return ~1 if no item is found, for the sake of less ambiguity in usage. Functions that call these have also been adapted.
This commit is contained in:
@@ -29,7 +29,10 @@ struct
|
||||
Utils.getRelativeLineStartFromRightHead (startLine, curLine, lhd)
|
||||
(* get absolute idx of line *)
|
||||
val absIdx = curIdx + strPos
|
||||
|
||||
val searchPos = BinSearch.equalOrMore (absIdx, searchList)
|
||||
val searchPos =
|
||||
if searchPos = ~1 then Vector.length searchList else searchPos
|
||||
|
||||
val env = Utils.initEnv
|
||||
( windowWidth
|
||||
|
||||
Reference in New Issue
Block a user