Relax upper bound of T for minBy and maxBy to be nullable.

Swap type parameters of minBy and maxBy.
#KT-10099 Fixed
This commit is contained in:
Ilya Gorbunov
2015-11-30 18:19:25 +03:00
parent 58e93d5e1b
commit 33b366b9b9
4 changed files with 8 additions and 8 deletions
@@ -181,8 +181,8 @@ fun aggregates(): List<GenericFunction> {
inline(true)
doc { f -> "Returns the first ${f.element} yielding the smallest value of the given function or `null` if there are no ${f.element.pluralize()}." }
typeParam("T")
typeParam("R : Comparable<R>")
typeParam("T : Any")
returns("T?")
body {
"""
@@ -287,8 +287,8 @@ fun aggregates(): List<GenericFunction> {
inline(true)
doc { f -> "Returns the first ${f.element} yielding the largest value of the given function or `null` if there are no ${f.element.pluralize()}." }
typeParam("T")
typeParam("R : Comparable<R>")
typeParam("T : Any")
returns("T?")
body {
"""