[FIR2IR] Fix NPE on missing built-ins when using old stdlib
Specifically, this code was throwing when trying to get the symbol for IntrinsicConstEvaluation which is only available since 1.7. #KT-59151 Fixed
This commit is contained in:
committed by
Space Team
parent
66bdb9ce79
commit
aa4ebe1991
+11
@@ -63,6 +63,17 @@ class CustomK2Tests : KGPBaseTest() {
|
||||
}
|
||||
}
|
||||
|
||||
@GradleTest
|
||||
@DisplayName("HMPP compilation with JS target and old stdlib. KT-59151")
|
||||
fun testHmppCompilationWithJsAndOldStdlib(gradleVersion: GradleVersion) {
|
||||
with(project("k2-mpp-js-old-stdlib", gradleVersion, buildOptions = defaultBuildOptions.copy(languageVersion = "2.0"))) {
|
||||
val taskToExecute = ":compileKotlinJs"
|
||||
build(taskToExecute) {
|
||||
assertTasksExecuted(taskToExecute)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@GradleTest
|
||||
@DisplayName("Native metadata of intermediate with reference to internal in common. KT-58219")
|
||||
fun nativeMetadataOfIntermediateWithReferenceToInternalInCommon(gradleVersion: GradleVersion) {
|
||||
|
||||
+32
@@ -0,0 +1,32 @@
|
||||
import org.jetbrains.kotlin.gradle.dsl.KotlinVersion
|
||||
import org.jetbrains.kotlin.gradle.tasks.KotlinCompilationTask
|
||||
|
||||
plugins {
|
||||
kotlin("multiplatform")
|
||||
}
|
||||
|
||||
repositories {
|
||||
mavenLocal()
|
||||
mavenCentral()
|
||||
}
|
||||
|
||||
kotlin {
|
||||
js {
|
||||
nodejs()
|
||||
browser()
|
||||
}
|
||||
|
||||
sourceSets {
|
||||
val commonMain by getting {
|
||||
dependencies {
|
||||
implementation(kotlin("stdlib-common", "1.6.21"))
|
||||
}
|
||||
}
|
||||
|
||||
val jsMain by getting {
|
||||
dependencies {
|
||||
implementation(kotlin("stdlib-js", "1.6.21"))
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
+1
@@ -0,0 +1 @@
|
||||
kotlin.stdlib.default.dependency=false
|
||||
Reference in New Issue
Block a user