com.jtransc.ds.MapExt.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jtransc-utils Show documentation
Show all versions of jtransc-utils Show documentation
JVM AOT compiler currently generating JavaScript, C++, Haxe, with initial focus on Kotlin and games.
package com.jtransc.ds
inline fun MutableMap.getOrPut2(key: T1, generator: () -> T2): T2 {
if (key !in this) this[key] = generator()
return this[key]!!
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy