diff --git a/jps/jps-common/src/org/jetbrains/kotlin/platform/IdePlatformKind.kt b/jps/jps-common/src/org/jetbrains/kotlin/platform/IdePlatformKind.kt index e4315c5c527..395db967918 100644 --- a/jps/jps-common/src/org/jetbrains/kotlin/platform/IdePlatformKind.kt +++ b/jps/jps-common/src/org/jetbrains/kotlin/platform/IdePlatformKind.kt @@ -51,9 +51,8 @@ abstract class IdePlatformKind> { val IDE_PLATFORMS_BY_COMPILER_PLATFORMS by lazy { ALL_KINDS.map { it.compilerPlatform to it }.toMap() } - fun platformByCompilerArguments(arguments: Args): IdePlatform<*, Args> { - return ALL_KINDS.firstNotNullResult { it.platformByCompilerArguments(arguments) as IdePlatform<*, Args>? }!! - } + fun platformByCompilerArguments(arguments: Args): IdePlatform<*, *>? = + ALL_KINDS.firstNotNullResult { it.platformByCompilerArguments(arguments) } } }