1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
package kotlin class Array<T> class IntArray class CharArray /** * Returns true if foo. */ fun IntArray.foo(predicate: (Int) -> Boolean): Boolean = false /** * Returns true if foo. */ fun CharArray.foo(predicate: (Char) -> Boolean): Boolean = false /** * Returns true if foo. */ fun <T> Array<T>.foo(predicate: (T) -> Boolean): Boolean = false