Accept in-projection of Comparator as a parameter when possible.

This commit is contained in:
Ilya Gorbunov
2015-09-07 21:27:50 +03:00
parent 37d5a16a3d
commit 52f3e9ca06
5 changed files with 5 additions and 5 deletions
@@ -108,7 +108,7 @@ fun specialJVM(): List<GenericFunction> {
}
}
templates add f("binarySearch(element: T, comparator: Comparator<T>, fromIndex: Int = 0, toIndex: Int = size())") {
templates add f("binarySearch(element: T, comparator: Comparator<in T>, fromIndex: Int = 0, toIndex: Int = size())") {
only(ArraysOfObjects)
doc { "Searches array or range of array for provided element index using binary search algorithm. Array is expected to be sorted according to the specified [comparator]." }
returns("Int")