miha-x64
04/24/2017, 11:14 AM(Something)->R?
instead of (Something)->R
?
private inline fun <reified K : Enum<K>, V, R> EnumMap<out K, V>.mapValuesIfNotNull(transform: (Map.Entry<K, V>) -> R?): Map<K, R> {
return mapValuesTo(EnumMap<K, R>(K::class.java), transform) // nullable return type ^
}