[minor] Renames and rearrangements for clarity

This commit is contained in:
Ilya Chernikov
2018-03-28 14:28:07 +02:00
parent 5058c66e8c
commit 4a4edf3458
22 changed files with 58 additions and 49 deletions
@@ -6,7 +6,7 @@
package kotlin.script.experimental.misc
import kotlin.reflect.KClass
import kotlin.script.experimental.api.TypedKey
import kotlin.script.experimental.util.TypedKey
inline operator fun <reified T> TypedKey<T>.invoke(v: T): Pair<TypedKey<T>, T> = this to v
@@ -15,9 +15,6 @@ inline operator fun <reified K> TypedKey<KClass<*>>.invoke(): Pair<TypedKey<KCla
inline operator fun <reified E> TypedKey<List<E>>.invoke(vararg vs: E): Pair<TypedKey<List<E>>, List<E>> = this to vs.toList()
@JvmName("invokeIterable")
inline operator fun <reified E> TypedKey<Iterable<E>>.invoke(vararg vs: E): Pair<TypedKey<Iterable<E>>, Iterable<E>> = this to vs.toList()
inline operator fun <reified K, reified V> TypedKey<Map<K, V>>.invoke(vararg vs: Pair<K, V>): Pair<TypedKey<Map<K, V>>, Map<K, V>> =
this to hashMapOf(*vs)