Kotlin 2.0.10-RC
Pre-release
Pre-release
Changelog
Apple Ecosystem
KT-68257Xcode incorrectly reuses embedAndSign framework when moving to and from 2.0.0
Compiler
Fixes
KT-68521K2: Property's private setters can be bypassed when using plusAssign and minusAssign operatorsKT-68667K2: Compiler hangs on mapNotNull and elvis inside lambdaKT-68747K2: Long compilation time because of constraint solving when using typealias in different modulesKT-68940K2: "IllegalArgumentException: All variables should be fixed to something"KT-68797K2 / Native: "java.lang.IllegalStateException: FIELD" caused by enabled cachingKT-68362False-positive ABSTRACT_MEMBER_NOT_IMPLEMENTED for inheritor of java class which directly implements java.util.MapKT-68449K2: "when" expression returns UnitKT-67072K2: inconsistent stability of open vals on receivers of final typeKT-68570K2: "Unresolved reference" in call with lambda argument and nested lambda argumentKT-69159K2: KotlinNothingValueException in ExposedKT-68623K2: "Only safe or null-asserted calls are allowed" on safe callKT-68193JDK 21: new MutableList.addFirst/addLast methods allow adding nullable value for non-null typesKT-67804removeFirst and removeLast return type with Java 21KT-68727K2: "Null argument in ExpressionCodegen for parameter VALUE_PARAMETER" caused by an enum class with default parameter in a different moduleKT-68383K2: "Argument type mismatch: actual type is 'kotlin.String', but 'T & Any' was expected." with intersection typesKT-68546K2: false-positive conflicting overloads error on inheriting generic type with inherited generic and non-generic member overloadsKT-68626K2: "Conflicting Overloads" for function if inherited from generic typeKT-68351K2: "Suspension functions can only be called within coroutine body"KT-68489K2: WRONG_ANNOTATION_TARGET with Java and Kotlin@Targetannotation positionsKT-69058K2: Java-defined property annotations not persistedKT-64515K2 IDE: [NEW_INFERENCE_ERROR] in a build.gradle.kts script while applying "jvm-test-suite" plugin and then configuring targets for test suitesKT-68016K2: Gradle repo testshould compile correctly with Kotlin explicit api modefails on K2KT-68575K2:@ParameterNameannotation is not erased when inferring the type ofitin lambdasKT-67999K2: lost flexibility on parameters of Java SAMKT-59679K2: Investigate extracting uncompleted candidates from blocksKT-68401K2: "IllegalAccessError: failed to access class" caused by package private super Java type, when inferencing a common super type of if or when branches on JVMKT-68806K/Wasm RuntimeError: unreachable on Sequence::toListKT-68455K2: False negative UPPER_BOUND_VIOLATED_BASED_ON_JAVA_ANNOTATIONSKT-68538KJS/K2: usingwhilewithbreakinside inline lambdas leads to an endless cycleKT-68798JVM compiler crashes on calling private expect constructor with a default parameterKT-68734K2: enum class in KMP: Expect declarationMMKVLogLevelis incompatible with actualMMKVLogLevelbecause modality is differentKT-68674False positive ACTUAL_WITHOUT_EXPECT in K2KT-68350K2: "Inapplicable candidate(s)" caused by parameter reference of local class with type parameters from functionKT-68571K2: "IllegalStateException: Fake override should have at least one overridden descriptor" caused by exceptions and when statementKT-68523K2: FileAnalysisException when using Definitely non-nullable typesKT-68339K2: "Enum entry * is uninitialized here" caused by lazy property with enum inwhenexpressionKT-66688K2: false-negative "upper bound violated" error in extension receiverKT-68630DiagnosticsSuppressor is not invoked with Kotlin 2.0KT-68222K2. KMP. False negativeExpected declaration must not have a bodyfor expected top-level property with getter/setterKT-64103FirExpectActualDeclarationChecker reports diagnostic error for KtPsiSimpleDiagnostic with KtFakeSourceElementKT-68191K2. Static fake-overrides are not generated for kotlin Fir2IrLazyClassKT-68024K2: Gradle repo testaccessors to kotlin internal task types...fails on K2KT-64957K1: drop ModuleAnnotationResolver
Compose compiler
0c5a858Fix memoization of captureless lambdas when K2 compiler is used b/340582180a8249d6Allow memoizing lambdas in composable inline functions b/340606661
Native
KT-68094K2/Native: Member inherits different '@Throws' when inheriting from generic type
Tools. Compiler Plugins
KT-69187Compose compiler for web doesn't support rememberComposableLambdaKT-68557K2. Supertypes resolution of KJK hierarchy fails in presence of allopen plugin
Tools. Compiler plugins. Serialization
KT-68850Compose lambda type not transformed with KGP 2 + new Compose plugin
Tools. Daemon
KT-68297KGP 2.0 regression: JAVA_TOOL_OPTIONS is not considered in Kotlin daemon creation
Tools. Gradle
KT-69330KotlinCompile friendPathsSet property is racy due causing build cache invalidationKT-69026Mark AGP 8.5.0 as compatible with KGPKT-68447ill-added intentionally-broken dependency source configurationsKT-69078Gradle: Add option to disable FUS ServiceKT-68278Spring resource loading in combination withjava-test-fixturesplugin brokenKT-66452Gradle produces false positive configuration cache problem for Project usage at execution timeKT-68242Run tests against AGP 8.4.0
Tools. Gradle. Multiplatform
KT-68805KMP project (re-)import took a long time for downloading platform libsKT-68248kotlin multiplatform project fail to build on Fedora with corretto
Tools. Gradle. Native
KT-68638KGP 2.0 breaks native test with api dependencies and configuration cacheKT-65761Missing JDK Platform ClassLoader when compiling Kotlin native in daemon
Tools. JPS
KT-69204Generate lookups in dumb mode for compatibility with ref index
Tools. Kapt
KT-68171K2KAPT: boxed return types in overridden methods changed to primitives