Kotlin: Make with an inline function

This commit is contained in:
Ian Lynagh
2022-01-21 12:11:25 +00:00
parent 3cc79f8b56
commit f985671d7f

View File

@@ -35,7 +35,7 @@ open class KotlinFileExtractor(
genericSpecialisationsExtracted: MutableSet<String>
): KotlinUsesExtractor(logger, tw, dependencyCollector, externalClassExtractor, primitiveTypeMapping, pluginContext, genericSpecialisationsExtracted) {
fun <T> with(kind: String, element: IrElement, f: () -> T): T {
inline fun <T> with(kind: String, element: IrElement, f: () -> T): T {
try {
return f()
} catch(exception: Exception) {