Skip to content

Releases: JetBrains/kotlin

Kotlin 2.0.20

22 Aug 11:10
Compare
Choose a tag to compare

Changelog

Analysis. API

New Features

  • KT-68143 Analysis API: support KtWhenConditionInRange call resolution

Performance Improvements

  • KT-67195 K2: do not call redundant resolve on body resolution phase for classes

Fixes

  • KT-67360 Analysis API: KtDestructuringDeclarationSymbol#entries shouldn't be KtLocalVariableSymbol
  • KT-67748 K2: AllCandidatesResolver modifies the original FirDelegatedConstructorCall
  • KT-68198 Analysis API: Support application service registration in plugin XMLs
  • KT-62936 Analysis API: NativeForwardDeclarationsSymbolProvider is not supported for Kotlin/Native
  • KT-68689 LL API: support analysis from builtins module
  • KT-69630 KAPT User project builds with KAPT4 enabled fail with Metaspace overflow
  • KT-65417 K2 IDE: KTOR false positive expect-actual matching error on enum class because of implicit clone() in non-JVM source sets
  • KT-68882 Analysis API: Refactor KaSymbols
  • KT-65413 K2 IDE: KTOR unresolved serializer() call for @Serializable class in common code
  • KT-67996 Analysis API: rename Kt prefix to Ka
  • KT-67775 Analysis API: expose only interfaces/abstract classes for the user surface
  • KT-68009 K2: lowering transformers of Compose compiler plugin access AbstractFir2IrLazyFunction modality, which results in null point exception
  • KT-68918 collectCallCandidates works incorrectly for parenthesis invoke
  • KT-68462 Analysis API: Integrate project-structure module into analysis-api and analysis-api-platform-interface
  • KT-69131 AA: "provideDelegate" operator is not resolved from the delegation reference in FIR implementation
  • KT-69055 Analysis API: Stabilize KaScopes
  • KT-66216 K2 IDE. "FirDeclaration was not found for class org.jetbrains.kotlin.psi.KtProperty, fir is null" on incorrect string template
  • KT-68959 Introduce KaSeverity
  • KT-53669 Analysis API: redesign KtSymbolOrigin to distinguish kotlin/java source/library declarations
  • KT-68846 Mark KaFirReference and all implementations with internal modifier
  • KT-68845 Move KaSymbolBasedReference to resolution package
  • KT-68844 Move KaTypeProjection to types package
  • KT-65849 K2: Rename 'high-level-api' family of JARs to 'analysis-api'
  • KT-62540 Remove uses of TypeInfo.fromString and TypeInfo.createTypeText from Kotlin plugin
  • KT-62889 K2 IDE. FP MISSING_DEPENDENCY_CLASS on not available type alias with available underlying type
  • KT-68155 Analysis API: Add PSI validity check to analyze
  • KT-62343 Analysis API: fix binary incopatibility problems cause by KtAnalysisSessionProvider.analyze being inline
  • KT-68498 To get reference symbol the one should be KtSymbolBasedReference
  • KT-68393 Analysis API: Rename KaClassLikeSymbol. classIdIfNonLocal to classId
  • KT-62924 Analysis API: rename KtCallableSymbol.callableIdIfNonLocal -> callableId
  • KT-66712 K2 IDE. SOE on settings string template for string variable with the same name
  • KT-65892 K2: "We should be able to find a symbol" for findNonLocalFunction
  • KT-68273 AA: support KtFirKDocReference#isReferenceToImportAlias
  • KT-68272 AA: KtFirReference.isReferenceToImportAlias doesn't work for references on constructor
  • KT-66996 Analysis API: Expose the abbreviated type of an expanded KtType
  • KT-66646 K2: Expected FirResolvedTypeRef with ConeKotlinType but was FirUserTypeRefImpl from FirJsHelpersKt.isExportedObject
  • KT-68203 K2: Analysis API: wrong type of receiver value in case of imported object member
  • KT-68031 LL resolve crash in case of PCLA inference with local object
  • KT-67851 K2: PsiReference#isReferenceTo always returns false for references to Java getters
  • KT-68076 AA: use type code fragments for import alias detection
  • KT-65915 K2: Analysis API: extract services registration into xml file
  • KT-68049 Analysis API: do not expose imported symbols
  • KT-68075 K2: Analysis API: Type arguments for delegation constructor to java constructor with type parameters not supported
  • KT-65190 AA: reference to the super type is not resolved
  • KT-68070 AA: KtExpressionInfoProvider#isUsedAsExpression doesn't work for KtPropertyDelegate
  • KT-67743 K2: Stubs & AbbreviatedTypeAttribute
  • KT-67706 K2: "KtDotQualifiedExpression is not a subtype of class KtNamedDeclaration" from UnusedChecker
  • KT-68021 Analysis API: do not break the diagnostic collection in a case of exception from some collector
  • KT-67973 AA FIR: wrong KtCall modeling for == from type bound
  • KT-67949 AA: Type arguments of Java methods' calls are not reported as used by KtFirImportOptimizer
  • KT-67988 AA: functional type at receiver position should be wrapped in parenthesis
  • KT-66536 Analysis API: ContextCollector doesn't provide implicit receivers from FirExpressionResolutionExtension
  • KT-67321 AA: Type arguments of Java methods' calls are not resolved
  • KT-64158 K2: "KotlinIllegalArgumentExceptionWithAttachments: No fir element was found for KtParameter"
  • KT-60344 K2 IDE. "KotlinExceptionWithAttachments: expect createKtCall to succeed for resolvable case with callable symbol" on attempt to assign value to param named getParam
  • KT-64599 K2: "expect createKtCall to succeed for resolvable case with callable" for unfinished if statement
  • KT-60330 K2 IDE. ".KotlinExceptionWithAttachments: expect createKtCall to succeed for resolvable case with callable symbol" on attempt to assign or compare true with something
  • KT-66672 K2 IDE. False positive INVISIBLE_REFERENCE on accessing private subclass as type argument in parent class declaration
  • KT-67750 Analysis API: Remove infix modifiers from type equality and subtyping functions
  • KT-67655 Analysis API: declare a rule how to deal with parameters in KtLifetimeOwner
  • KT-61775 Analysis API: KtKClassAnnotationValue lacks complete type information
  • KT-67168 K2: Analysis API: Rendering is broken for JSR-305 enhanced Java types
  • KT-66689 Analysis API: KtFirPackageScope shouldn't rely on KotlinDeclarationProvider for binary dependencies in standalone mode
  • KT-60483 Analysis API: add isTailrec property to KtFunctionSymbol
  • KT-67472 K2: Analysis API FIR: KtFunctionCall misses argument with desugared expressions
  • KT-65759 Analysis API: Avoid hard references to LLFirSession in session validity trackers
  • KT-60272 K2: Implement active invalidation of KtAnalysisSessions
  • KT-66765 K2: Analysis API: support classpath substituti...
Read more

Kotlin 2.0.20-RC2

13 Aug 12:18
Compare
Choose a tag to compare
Kotlin 2.0.20-RC2 Pre-release
Pre-release

Changelog

Backend. Wasm

  • KT-70591 To much sources that don't exist inside SourceMap file

Compiler

  • KT-70186 Kotlin 2.0.20-Beta2: Unexpected number of type arguments: 0
  • KT-69835 K2 / Native: kotlin.native.binary.gc=cms throws library cached but its dependency isn't error
  • KT-70417 DELEGATED_MEMBER_HIDES_SUPERTYPE_OVERRIDE leads to NPE in BE
  • KT-69964 K2: Returning from an in-place lambda doesn't compile
  • KT-69995 K2: Slow compilation when star projecting mutually recursive bounds from java
  • KT-69773 K2: "Overload resolution ambiguity between candidate" with arrays
  • KT-70238 K2: false negative VOLATILE_ON_VALUE for constructor properties
  • KT-69766 K2: False negative: Internal setter of generic class is accessible from another module
  • KT-69898 K2: Performance degradation in fir2ir caused by changes around intersection types

Compose compiler

  • b/357878245 Disallow open @Composable functions with default params to fix binary compatibility issues.

JavaScript

  • KT-70592 "Error: HttpClientCall expected" on HTTP request when targeting es2015 with KTOR
  • KT-67355 KJS / ES6: 'super' in lambda with enabled -Xir-generate-inline-anonymous-functions leads to JS errors

Libraries

  • KT-70196 Introduce ExperimentalUuidApi annotation for marking Uuid API

Native

  • KT-70166 Native: EXC_BAD_ACCESS on watchOS when using Dispatchers
  • KT-69246 K2: linkPodDebugFrameworkIosArm64 takes 15 (!!) times longer

Native. Runtime

  • KT-70043 Native: EXC_BAD_ACCESS on watchOS when using Random

Tools. Compiler plugins. Serialization

  • KT-70516 KxSerialization: @KeepGeneratedSerializer and sealed class cause initialization error

Tools. Gradle. JS

  • KT-70077 [2.0.20-Beta2] KGP reports confusing warnings about js/wasmJS source sets

Tools. Wasm

  • KT-70220 K/Wasm: Upgrade NPM dependencies

Kotlin 2.0.20-RC

30 Jul 09:57
Compare
Choose a tag to compare
Kotlin 2.0.20-RC Pre-release
Pre-release

2.0.20-RC

Analysis. API

  • KT-69630 KAPT User project builds with KAPT4 enabled fail with Metaspace overflow

Backend. Wasm

  • KT-69876 K2 Compile exception: Only IrBlockBody together with kotlinx serialization
  • KT-69529 compileProductionExecutableKotlinWasmJs FAILED: No such value argument slot in IrConstructorCallImpl: 1 (total=1)
  • KT-68088 Wasm: "UNREACHABLE executed at Precompute.cpp:838" running gradle task wasmJsBrowserDistribution for compose multiplatform on Windows

Compiler

  • KT-69494 StackOverflowError in CfgTraverserKt.getPreviousCfgNodes
  • KT-69723 K2: code analysis taking too long
  • KT-56880 K2. Conflicting overloads for main() isn't shown when language version is set to 2.0
  • KT-69170 K2: "Unresolved reference" caused by generics and fun interfaces
  • KT-70039 K2: inconsistent stability of vals of captured receivers
  • KT-68996 K2: "Not enough information to infer type argument" caused by typealias annotation with fixed generic argument
  • KT-68889 K2: type variable should not be fixed
  • KT-15388 Forbid delegated property to have external getter/setter

Compose compiler

  • b/351858979 Fix stability inferencing of interfaces on incremental compilation
  • b/346821372 [Compose] Fix code generation for group optimization

JavaScript

  • KT-69353 KJS / d.ts: Kotlin does not export base collection classes along with their mutable collection counterparts

Libraries

  • KT-68025 Improve documentation for Hex

Native. Build Infrastructure

  • KT-69781 Kotlin/Native performance tests fail to compile with bitcode

Native. C and ObjC Import

  • KT-69094 LLVM 11 clang: cinterops fail with "_Float16 is not supported on this target"

Native. Platform Libraries

  • KT-69382 LLVM 11 clang: symbol not found when running the linker

Native. Runtime

  • KT-68928 EXC_BREAKPOINT: BUG IN CLIENT OF LIBPLATFORM: Trying to recursively lock an os_unfair_lock

Tools. CLI

  • KT-69792 Add the possibility to disable fast jar fs in K2

Tools. Gradle

  • KT-69809 Compose Gradle Plugin: AGP doesn't override configuration properties like traceMarkersEnabled
  • KT-68843 Gradle: Kotlin plugin changes source set 'main' to 'null/main'
  • KT-69837 Deprecation warning for file-based IC is issued when the property is set to true, altering the intended meaning of the message

Tools. Gradle. JS

  • KT-69805 YarnSetupTask does not work for custom downloadBaseUrl

Tools. Gradle. Multiplatform

  • KT-69311 runDebugExecutable task fails with "this.compilation" is null with enabled configuration cache

Tools. Gradle. Native

  • KT-69918 java.lang.NullPointerException: Cannot invoke "org.jetbrains.kotlin.gradle.plugin.mpp.KotlinNativeCompilation.getTarget()" because "this.compilation" is null

Tools. Incremental Compile

  • KT-69042 K2: changing a Java constant won't cause Kotlin usages to recompile

Tools. JPS

  • KT-69204 Generate lookups in dumb mode for compatibility with ref index

Kotlin 2.0.10

06 Aug 10:58
Compare
Choose a tag to compare

2.0.10

Apple Ecosystem

  • KT-68257 Xcode incorrectly reuses embedAndSign framework when moving to and from 2.0.0

Compiler

Fixes

  • KT-69876 K2 Compile exception: Only IrBlockBody together with kotlinx serialization
  • KT-68521 K2: Property's private setters can be bypassed when using plusAssign and minusAssign operators
  • KT-68667 K2: Compiler hangs on mapNotNull and elvis inside lambda
  • KT-68747 K2: Long compilation time because of constraint solving when using typealias in different modules
  • KT-68940 K2: "IllegalArgumentException: All variables should be fixed to something"
  • KT-68797 K2 / Native: "java.lang.IllegalStateException: FIELD" caused by enabled caching
  • KT-68362 False-positive ABSTRACT_MEMBER_NOT_IMPLEMENTED for inheritor of java class which directly implements java.util.Map
  • KT-68449 K2: "when" expression returns Unit
  • KT-67072 K2: inconsistent stability of open vals on receivers of final type
  • KT-68570 K2: "Unresolved reference" in call with lambda argument and nested lambda argument
  • KT-69159 K2: KotlinNothingValueException in Exposed
  • KT-68623 K2: "Only safe or null-asserted calls are allowed" on safe call
  • KT-68193 JDK 21: new MutableList.addFirst/addLast methods allow adding nullable value for non-null types
  • KT-67804 removeFirst and removeLast return type with Java 21
  • KT-68727 K2: "Null argument in ExpressionCodegen for parameter VALUE_PARAMETER" caused by an enum class with default parameter in a different module
  • KT-68383 K2: "Argument type mismatch: actual type is 'kotlin.String', but 'T & Any' was expected." with intersection types
  • KT-68546 K2: false-positive conflicting overloads error on inheriting generic type with inherited generic and non-generic member overloads
  • KT-68626 K2: "Conflicting Overloads" for function if inherited from generic type
  • KT-68351 K2: "Suspension functions can only be called within coroutine body"
  • KT-68489 K2: WRONG_ANNOTATION_TARGET with Java and Kotlin @Target annotation positions
  • KT-69058 K2: Java-defined property annotations not persisted
  • KT-64515 K2 IDE: [NEW_INFERENCE_ERROR] in a build.gradle.kts script while applying "jvm-test-suite" plugin and then configuring targets for test suites
  • KT-68016 K2: Gradle repo test should compile correctly with Kotlin explicit api mode fails on K2
  • KT-68575 K2: @ParameterName annotation is not erased when inferring the type of it in lambdas
  • KT-67999 K2: lost flexibility on parameters of Java SAM
  • KT-59679 K2: Investigate extracting uncompleted candidates from blocks
  • KT-68401 K2: "IllegalAccessError: failed to access class" caused by package private super Java type, when inferencing a common super type of if or when branches on JVM
  • KT-68806 K/Wasm RuntimeError: unreachable on Sequence::toList
  • KT-68455 K2: False negative UPPER_BOUND_VIOLATED_BASED_ON_JAVA_ANNOTATIONS
  • KT-68538 KJS/K2: using while with break inside inline lambdas leads to an endless cycle
  • KT-68798 JVM compiler crashes on calling private expect constructor with a default parameter
  • KT-68734 K2: enum class in KMP: Expect declaration MMKVLogLevel is incompatible with actual MMKVLogLevel because modality is different
  • KT-68674 False positive ACTUAL_WITHOUT_EXPECT in K2
  • KT-68350 K2: "Inapplicable candidate(s)" caused by parameter reference of local class with type parameters from function
  • KT-68571 K2: "IllegalStateException: Fake override should have at least one overridden descriptor" caused by exceptions and when statement
  • KT-68523 K2: FileAnalysisException when using Definitely non-nullable types
  • KT-68339 K2: "Enum entry * is uninitialized here" caused by lazy property with enum in when expression
  • KT-66688 K2: false-negative "upper bound violated" error in extension receiver
  • KT-68630 DiagnosticsSuppressor is not invoked with Kotlin 2.0
  • KT-68222 K2. KMP. False negative Expected declaration must not have a body for expected top-level property with getter/setter
  • KT-64103 FirExpectActualDeclarationChecker reports diagnostic error for KtPsiSimpleDiagnostic with KtFakeSourceElement
  • KT-68191 K2. Static fake-overrides are not generated for kotlin Fir2IrLazyClass
  • KT-68024 K2: Gradle repo test accessors to kotlin internal task types... fails on K2
  • KT-64957 K1: drop ModuleAnnotationResolver

Compose compiler

Native

  • KT-68094 K2/Native: Member inherits different '@Throws' when inheriting from generic type

Tools. Compiler Plugins

  • KT-69187 Compose compiler for web doesn't support rememberComposableLambda
  • KT-68557 K2. Supertypes resolution of KJK hierarchy fails in presence of allopen plugin

Tools. Compiler plugins. Serialization

  • KT-68850 Compose lambda type not transformed with KGP 2 + new Compose plugin

Tools. Daemon

  • KT-68297 KGP 2.0 regression: JAVA_TOOL_OPTIONS is not considered in Kotlin daemon creation

Tools. Gradle

  • KT-69330 KotlinCompile friendPathsSet property is racy due causing build cache invalidation
  • KT-69026 Mark AGP 8.5.0 as compatible with KGP
  • KT-68447 ill-added intentionally-broken dependency source configurations
  • KT-69078 Gradle: Add option to disable FUS Service
  • KT-68278 Spring resource loading in combination with java-test-fixtures plugin broken
  • KT-66452 Gradle produces false positive configuration cache problem for Project usage at execution time
  • KT-68242 Run tests against AGP 8.4.0

Tools. Gradle. Multiplatform

  • KT-68805 KMP project (re-)import took a long time for downloading platform libs
  • KT-68248 kotlin multiplatform project fail to build on Fedora with corretto

Tools. Gradle. Native

  • KT-68638 KGP 2.0 breaks native test with api dependencies and configuration cache
  • KT-65761 Missing JDK Platform ClassLoader when compiling Kotlin native in daemon

Tools. JPS

  • KT-69204 Generate lookups in dumb mode for compatibility with ref index

Tools. Kapt

  • KT-68171 K2KAPT: boxed return types in overridden methods changed to primitives

Tools. Scripts

  • KT-68681 K2 / CLI / Script: "NullPointerException: getService(...) must not be null" caused by @DependsOn
  • KT-67747 K2...
Read more

Kotlin 2.0.10-RC2

29 Jul 12:16
Compare
Choose a tag to compare
Kotlin 2.0.10-RC2 Pre-release
Pre-release

2.0.10-RC2

Frontend

  • KT-69876 K2 Compile exception: Only IrBlockBody together with kotlinx serialization

Kotlin 1.9.25

19 Jul 12:52
Compare
Choose a tag to compare

Note: This is a technical release for IntelliJ IDEA.

Changelog

Tools. JPS

  • KT-69204 Generate lookups in dumb mode for compatibility with ref index

Kotlin 2.0.10-RC

11 Jul 16:09
Compare
Choose a tag to compare
Kotlin 2.0.10-RC Pre-release
Pre-release

Changelog

Apple Ecosystem

  • KT-68257 Xcode incorrectly reuses embedAndSign framework when moving to and from 2.0.0

Compiler

Fixes

  • KT-68521 K2: Property's private setters can be bypassed when using plusAssign and minusAssign operators
  • KT-68667 K2: Compiler hangs on mapNotNull and elvis inside lambda
  • KT-68747 K2: Long compilation time because of constraint solving when using typealias in different modules
  • KT-68940 K2: "IllegalArgumentException: All variables should be fixed to something"
  • KT-68797 K2 / Native: "java.lang.IllegalStateException: FIELD" caused by enabled caching
  • KT-68362 False-positive ABSTRACT_MEMBER_NOT_IMPLEMENTED for inheritor of java class which directly implements java.util.Map
  • KT-68449 K2: "when" expression returns Unit
  • KT-67072 K2: inconsistent stability of open vals on receivers of final type
  • KT-68570 K2: "Unresolved reference" in call with lambda argument and nested lambda argument
  • KT-69159 K2: KotlinNothingValueException in Exposed
  • KT-68623 K2: "Only safe or null-asserted calls are allowed" on safe call
  • KT-68193 JDK 21: new MutableList.addFirst/addLast methods allow adding nullable value for non-null types
  • KT-67804 removeFirst and removeLast return type with Java 21
  • KT-68727 K2: "Null argument in ExpressionCodegen for parameter VALUE_PARAMETER" caused by an enum class with default parameter in a different module
  • KT-68383 K2: "Argument type mismatch: actual type is 'kotlin.String', but 'T & Any' was expected." with intersection types
  • KT-68546 K2: false-positive conflicting overloads error on inheriting generic type with inherited generic and non-generic member overloads
  • KT-68626 K2: "Conflicting Overloads" for function if inherited from generic type
  • KT-68351 K2: "Suspension functions can only be called within coroutine body"
  • KT-68489 K2: WRONG_ANNOTATION_TARGET with Java and Kotlin @Target annotation positions
  • KT-69058 K2: Java-defined property annotations not persisted
  • KT-64515 K2 IDE: [NEW_INFERENCE_ERROR] in a build.gradle.kts script while applying "jvm-test-suite" plugin and then configuring targets for test suites
  • KT-68016 K2: Gradle repo test should compile correctly with Kotlin explicit api mode fails on K2
  • KT-68575 K2: @ParameterName annotation is not erased when inferring the type of it in lambdas
  • KT-67999 K2: lost flexibility on parameters of Java SAM
  • KT-59679 K2: Investigate extracting uncompleted candidates from blocks
  • KT-68401 K2: "IllegalAccessError: failed to access class" caused by package private super Java type, when inferencing a common super type of if or when branches on JVM
  • KT-68806 K/Wasm RuntimeError: unreachable on Sequence::toList
  • KT-68455 K2: False negative UPPER_BOUND_VIOLATED_BASED_ON_JAVA_ANNOTATIONS
  • KT-68538 KJS/K2: using while with break inside inline lambdas leads to an endless cycle
  • KT-68798 JVM compiler crashes on calling private expect constructor with a default parameter
  • KT-68734 K2: enum class in KMP: Expect declaration MMKVLogLevel is incompatible with actual MMKVLogLevel because modality is different
  • KT-68674 False positive ACTUAL_WITHOUT_EXPECT in K2
  • KT-68350 K2: "Inapplicable candidate(s)" caused by parameter reference of local class with type parameters from function
  • KT-68571 K2: "IllegalStateException: Fake override should have at least one overridden descriptor" caused by exceptions and when statement
  • KT-68523 K2: FileAnalysisException when using Definitely non-nullable types
  • KT-68339 K2: "Enum entry * is uninitialized here" caused by lazy property with enum in when expression
  • KT-66688 K2: false-negative "upper bound violated" error in extension receiver
  • KT-68630 DiagnosticsSuppressor is not invoked with Kotlin 2.0
  • KT-68222 K2. KMP. False negative Expected declaration must not have a body for expected top-level property with getter/setter
  • KT-64103 FirExpectActualDeclarationChecker reports diagnostic error for KtPsiSimpleDiagnostic with KtFakeSourceElement
  • KT-68191 K2. Static fake-overrides are not generated for kotlin Fir2IrLazyClass
  • KT-68024 K2: Gradle repo test accessors to kotlin internal task types... fails on K2
  • KT-64957 K1: drop ModuleAnnotationResolver

Compose compiler

Native

  • KT-68094 K2/Native: Member inherits different '@Throws' when inheriting from generic type

Tools. Compiler Plugins

  • KT-69187 Compose compiler for web doesn't support rememberComposableLambda
  • KT-68557 K2. Supertypes resolution of KJK hierarchy fails in presence of allopen plugin

Tools. Compiler plugins. Serialization

  • KT-68850 Compose lambda type not transformed with KGP 2 + new Compose plugin

Tools. Daemon

  • KT-68297 KGP 2.0 regression: JAVA_TOOL_OPTIONS is not considered in Kotlin daemon creation

Tools. Gradle

  • KT-69330 KotlinCompile friendPathsSet property is racy due causing build cache invalidation
  • KT-69026 Mark AGP 8.5.0 as compatible with KGP
  • KT-68447 ill-added intentionally-broken dependency source configurations
  • KT-69078 Gradle: Add option to disable FUS Service
  • KT-68278 Spring resource loading in combination with java-test-fixtures plugin broken
  • KT-66452 Gradle produces false positive configuration cache problem for Project usage at execution time
  • KT-68242 Run tests against AGP 8.4.0

Tools. Gradle. Multiplatform

  • KT-68805 KMP project (re-)import took a long time for downloading platform libs
  • KT-68248 kotlin multiplatform project fail to build on Fedora with corretto

Tools. Gradle. Native

  • KT-68638 KGP 2.0 breaks native test with api dependencies and configuration cache
  • KT-65761 Missing JDK Platform ClassLoader when compiling Kotlin native in daemon

Tools. JPS

  • KT-69204 Generate lookups in dumb mode for compatibility with ref index

Tools. Kapt

  • KT-68171 K2KAPT: boxed return types in overridden methods changed to primitives

Tools. Scripts

  • KT-68681 K2 / CLI / Script: "NullPointerException: getService(...) must not be null" caused by @DependsOn
  • KT-67747 K2: regression in Spring unit tests using javax.script.ScriptEngine

Kotlin 2.0.20-Beta2

10 Jul 10:00
Compare
Choose a tag to compare
Kotlin 2.0.20-Beta2 Pre-release
Pre-release

Changelog

Analysis. API

Fixes

  • KT-65417 K2 IDE: KTOR false positive expect-actual matching error on enum class because of implicit clone() in non-JVM source sets
  • KT-68882 Analysis API: Refactor KaSymbols
  • KT-68689 LL API: support analysis from builtins module
  • KT-67775 Analysis API: expose only interfaces/abstract classes for the user surface
  • KT-68009 K2: lowering transformers of Compose compiler plugin access AbstractFir2IrLazyFunction modality, which results in null point exception
  • KT-68918 collectCallCandidates works incorrectly for parenthesis invoke
  • KT-68462 Analysis API: Integrate project-structure module into analysis-api and analysis-api-platform-interface
  • KT-69131 AA: "provideDelegate" operator is not resolved from the delegation reference in FIR implementation
  • KT-69055 Analysis API: Stabilize KaScopes
  • KT-68959 Introduce KaSeverity
  • KT-68846 Mark KaFirReference and all implementations with internal modifier
  • KT-68845 Move KaSymbolBasedReference to resolution package
  • KT-68844 Move KaTypeProjection to types package
  • KT-65849 K2: Rename 'high-level-api' family of JARs to 'analysis-api'
  • KT-62540 Remove uses of TypeInfo.fromString and TypeInfo.createTypeText from Kotlin plugin
  • KT-68155 Analysis API: Add PSI validity check to analyze
  • KT-62936 Analysis API: NativeForwardDeclarationsSymbolProvider is not supported for Kotlin/Native

Analysis. Light Classes

  • KT-68261 SLC: Constructors of sealed classes should be private
  • KT-68696 Drop DecompiledPsiDeclarationProvider-related stuff
  • KT-68404 SLC: wrong binary resolution to declaration with @JvmName

Backend. Native. Debug

  • KT-67567 Native: after updating to LLVM 16 lldb hangs when smooth stepping

Backend. Wasm

  • KT-68828 Wasm test failure. expect-actual. private constructor in expect

Compiler

New Features

  • KT-58310 Consider non-functional type constraints for type variable which is an expected type for lambda argument
  • KT-57872 Improve "Public-API inline function cannot access non-public-API" check

Fixes

  • KT-65546 K2. implement extended checker for unused anonymous parameter in lambda
  • KT-60445 K2/Java: investigate possible symbol clash while enhancing Java class type parameter bounds
  • KT-68358 @EnhancedNullability is missing on value parameter type after inheritance by delegation with strict JSpecify enabled
  • KT-67791 False negative "Synchronizing by Meters is forbidden" with inline value classes
  • KT-69495 k2: inconsistent output of unsigned number in string templates
  • KT-67693 Implement checkers for K1 compiler which will check the usage of K2 new features and report that they are not supported in K1 compiler
  • KT-44139 Don't report overload resolution ambiguities if arguments contain an error type
  • KT-69282 K2: equality of unsigned types with nullability works incorrectly
  • KT-69619 K2. JAVA_TYPE_MISMATCH when Kotlin out generic type used in Java
  • KT-68996 K2: "Not enough information to infer type argument" caused by typealias annotation with fixed generic argument
  • KT-69563 trying to call .source on FirPackageFragmentDescriptor results in exception
  • KT-69611 Internal annotation FlexibleArrayElementVariance is written to output jar
  • KT-69463 K2: false negative SUPER_CALL_WITH_DEFAULT_PARAMETERS with expect/actual declarations
  • KT-68556 K2: false negative PROPERTY_WITH_NO_TYPE_NO_INITIALIZER on uninitialized property without type
  • KT-68997 K2: "No accessor found" for an inline value class when query the value of a delegated class by reflection
  • KT-68724 K2: "ABSTRACT_MEMBER_NOT_IMPLEMENTED" caused by open modifier on interface
  • KT-68667 K2: Compiler hangs on mapNotNull and elvis inside lambda
  • KT-68747 K2: Long compilation time because of constraint solving when using typealias in different modules
  • KT-68940 K2: "IllegalArgumentException: All variables should be fixed to something"
  • KT-69182 K2: OptIn on enum companion blocks enum constants
  • KT-69191 K2: "Unresolved reference" caused by nested data objects
  • KT-68797 K2 / Native: "java.lang.IllegalStateException: FIELD" caused by enabled caching
  • KT-69569 Wrong paths when one type has multiple annotated arguments
  • KT-63871 K2: different value of isNotDefault flag for property inherited from delegate
  • KT-63828 K2: Missing signature metadata for accessors of properties inherited from delegate
  • KT-68669 K2: Generate inherited delegated members after actualization
  • KT-69402 FirSupertypeResolverVisitor: ConcurrentModificationException
  • KT-68449 K2: "when" expression returns Unit
  • KT-67072 K2: inconsistent stability of open vals on receivers of final type
  • KT-68570 K2: "Unresolved reference" in call with lambda argument and nested lambda argument
  • KT-69476 False negative NO_ELSE_IN_WHEN on when over intersection type with expect enum/sealed class
  • KT-67069 K2: Delegated member calls interface method instead of fake override
  • KT-63864 K2: Missing abbreviated type in metadata
  • KT-69421 K2: Resolve changed from delegated function to java default function
  • KT-69392 K2: "UNSAFE_CALL": when with some variable subjects does not smartcast the variable
  • KT-69159 K2: KotlinNothingValueException in Exposed
  • KT-69053 K2: Unsupported intersection overrides for fields
  • KT-69227 K2: "Argument type mismatch" caused by generic typealias and upper bound
  • KT-31371 NOT_YET_SUPPORTED_IN_INLINE: incorrect error message for local inline function
  • KT-49473 PROTECTED_CALL_FROM_PUBLIC_INLINE_ERROR: specialize error message for 'inline' property
  • KT-49474 NON_PUBLIC_CALL_FROM_PUBLIC_INLINE: specialize error message for 'inline' property
  • KT-49503 SUPER_CALL_FROM_PUBLIC_INLINE_ERROR: specialize error message for 'inline' property
  • KT-11302 On inapplicable '@JvmStatic' annotation, highlight only the annotation, not the function signature
  • KT-59510 K2: do not render annotations in the deprecation diagnostic
  • KT-68532 "This code uses error suppression for 'INAPPLICABLE_JVM_NAME'. While it might compile and work, the compiler behavior is UNSPECIFIED and WON'T BE PRESERVED"
  • KT-68859 K2: unable to suppress only "JAVA_MODULE_DOES_NOT_EXPORT_PACKAGE"
  • KT-68623 K2: "Only safe or null-asserted calls are allowed" on safe call
  • [KT-68364](https://y...
Read more

Kotlin 2.0.20-Beta1

18 Jun 08:48
Compare
Choose a tag to compare
Kotlin 2.0.20-Beta1 Pre-release
Pre-release

Changelog

Analysis. API

New Features

  • KT-68143 Analysis API: support KtWhenConditionInRange call resolution

Performance Improvements

  • KT-67195 K2: do not call redundant resolve on body resolution phase for classes

Fixes

  • KT-66216 K2 IDE. "FirDeclaration was not found for class org.jetbrains.kotlin.psi.KtProperty, fir is null" on incorrect string template
  • KT-53669 Analysis API: redesign KtSymbolOrigin to distinguish kotlin/java source/library declarations
  • KT-62889 K2 IDE. FP MISSING_DEPENDENCY_CLASS on not available type alias with available underlying type
  • KT-62343 Analysis API: fix binary incopatibility problems cause by KtAnalysisSessionProvider.analyze being inline
  • KT-68498 To get reference symbol the one should be KtSymbolBasedReference
  • KT-68393 Analysis API: Rename KaClassLikeSymbol. classIdIfNonLocal to classId
  • KT-62924 Analysis API: rename KtCallableSymbol.callableIdIfNonLocal -> callableId
  • KT-66712 K2 IDE. SOE on settings string template for string variable with the same name
  • KT-65892 K2: "We should be able to find a symbol" for findNonLocalFunction
  • KT-67360 Analysis API: KtDestructuringDeclarationSymbol#entries shouldn't be KtLocalVariableSymbol
  • KT-68198 Analysis API: Support application service registration in plugin XMLs
  • KT-68273 AA: support KtFirKDocReference#isReferenceToImportAlias
  • KT-68272 AA: KtFirReference.isReferenceToImportAlias doesn't work for references on constructor
  • KT-67996 Analysis API: rename Kt prefix to Ka
  • KT-66996 Analysis API: Expose the abbreviated type of an expanded KtType
  • KT-66646 K2: Expected FirResolvedTypeRef with ConeKotlinType but was FirUserTypeRefImpl from FirJsHelpersKt.isExportedObject
  • KT-68203 K2: Analysis API: wrong type of receiver value in case of imported object member
  • KT-68031 LL resolve crash in case of PCLA inference with local object
  • KT-67851 K2: PsiReference#isReferenceTo always returns false for references to Java getters
  • KT-68076 AA: use type code fragments for import alias detection
  • KT-65915 K2: Analysis API: extract services registration into xml file
  • KT-68049 Analysis API: do not expose imported symbols
  • KT-68075 K2: Analysis API: Type arguments for delegation constructor to java constructor with type parameters not supported
  • KT-65190 AA: reference to the super type is not resolved
  • KT-68070 AA: KtExpressionInfoProvider#isUsedAsExpression doesn't work for KtPropertyDelegate
  • KT-67748 K2: AllCandidatesResolver modifies the original FirDelegatedConstructorCall
  • KT-67743 K2: Stubs & AbbreviatedTypeAttribute
  • KT-67706 K2: "KtDotQualifiedExpression is not a subtype of class KtNamedDeclaration" from UnusedChecker
  • KT-68021 Analysis API: do not break the diagnostic collection in a case of exception from some collector
  • KT-67949 AA: Type arguments of Java methods' calls are not reported as used by KtFirImportOptimizer
  • KT-67988 AA: functional type at receiver position should be wrapped in parenthesis
  • KT-66536 Analysis API: ContextCollector doesn't provide implicit receivers from FirExpressionResolutionExtension
  • KT-67321 AA: Type arguments of Java methods' calls are not resolved
  • KT-64158 K2: "KotlinIllegalArgumentExceptionWithAttachments: No fir element was found for KtParameter"
  • KT-60344 K2 IDE. "KotlinExceptionWithAttachments: expect createKtCall to succeed for resolvable case with callable symbol" on attempt to assign value to param named getParam
  • KT-64599 K2: "expect createKtCall to succeed for resolvable case with callable" for unfinished if statement
  • KT-60330 K2 IDE. ".KotlinExceptionWithAttachments: expect createKtCall to succeed for resolvable case with callable symbol" on attempt to assign or compare true with something
  • KT-66672 K2 IDE. False positive INVISIBLE_REFERENCE on accessing private subclass as type argument in parent class declaration
  • KT-67750 Analysis API: Remove infix modifiers from type equality and subtyping functions
  • KT-67655 Analysis API: declare a rule how to deal with parameters in KtLifetimeOwner
  • KT-61775 Analysis API: KtKClassAnnotationValue lacks complete type information
  • KT-67168 K2: Analysis API: Rendering is broken for JSR-305 enhanced Java types
  • KT-66689 Analysis API: KtFirPackageScope shouldn't rely on KotlinDeclarationProvider for binary dependencies in standalone mode
  • KT-60483 Analysis API: add isTailrec property to KtFunctionSymbol
  • KT-67472 K2: Analysis API FIR: KtFunctionCall misses argument with desugared expressions
  • KT-65759 Analysis API: Avoid hard references to LLFirSession in session validity trackers
  • KT-60272 K2: Implement active invalidation of KtAnalysisSessions
  • KT-66765 K2: Analysis API: support classpath substitution with library dependencies in super type transformer
  • KT-67265 K2: status phase should resolve original declarations in the case of classpath subsitution
  • KT-67244 K2: StackOverflowError in the case of cyclic type hierarchy and library classpath substitution
  • KT-67080 K2: clearer contract for lazyResolveToPhaseWithCallableMembers
  • KT-65413 K2 IDE: KTOR unresolved serializer() call for @Serializable class in common code
  • KT-66713 K2 FIR: Expose a way to get the module name used for name mangling
  • KT-61892 KtType#asPsiType could provide nullability annotations
  • KT-66122 Analysis API: Pass KtTestModule instead of TestModule to tests based on AbstractAnalysisApiBasedTest

Analysis. Light Classes

  • KT-68275 LC: no arg constructor is not visible in light classes
  • KT-66687 Symbol Light Classes: Duplicate field names for classes with companion objects
  • KT-66804 Symbol Light Classes: Fields from the parent interface's companion are added to DefaultImpls

Apple Ecosystem

  • KT-68257 Xcode incorrectly reuses embedAndSign framework when moving to and from 2.0.0
  • KT-65542 Cinterop tasks fails if Xcode 15.3 is used

Backend. Wasm

  • KT-65798 K/Wasm: make an error on default export usage
  • KT-68453 K/Wasm: "Supported JS engine not detected" in Web Worker
  • KT-64565 Kotlin/wasm removeEventListener function did not remove the event listener
  • KT-66099 Wasm: local.get of type f64 has to be in the same reference type hierarchy as (ref 686) @+237036

Compiler

New Features

Read more

Kotlin 2.0.0

21 May 10:50
Compare
Choose a tag to compare

Changelog

Analysis. API

New Features

  • KT-65327 Support reading klib contents in Analysis API

Performance Improvements

  • KT-65560 K2: Anaysis API: ContextCollector triggers redundant resolution in the case of file elements
  • KT-64987 Analysis API: 50GB memory allocation on creating empty kotlinx.collections.immutable.persistentMapOf
  • KT-61789 K2: optimize getFirForNonKtFileElement for references inside super type reference
  • KT-59498 K2: getOnAirGetTowerContextProvider took too much time due to on air resolve
  • KT-61728 Analysis API: optimize AllCandidatesResolver.getAllCandidates

Fixes

  • KT-65561 Analysis API: dummy.kt is not a physical file
  • KT-65616 K2: FirDeclarationStatusImpl cannot be cast to FirResolvedDeclarationStatus from STATUS
  • KT-65600 Analysis Api: FirFile for KtCodeFragments are created and not updated on changes
  • KT-64919 K2 IDE: Implement KMP support for sealed class inheritors
  • KT-64241 K2: Unresolved calls to functions in scripts depending on included projects
  • KT-65813 Analysis API Standalone: FirDeclarationForCompiledElementSearcher does not find compiled elements
  • KT-66052 AA: render expect/actual modifier
  • KT-66795 KtCodeFragment.clone() is broken
  • KT-66532 K2 CodeGen AA: missing annotation setup for function in source module but not in a compile target file
  • KT-64833 Analysis API: Members implemented by delegation have no overridden symbols
  • KT-62405 Analysis API: Symbols SUBSTITUTION_OVERRIDE have no overridden symbols
  • KT-66749 K2: "Collection contains no element matching the predicate" on an unresolved call
  • KT-62832 K2: ClassCastException: FirDeclarationStatusImpl cannot be cast to FirResolvedDeclarationStatus
  • KT-66719 AbstractGetKlibSourceFileNameTest: The dependency to ":native:analysis-api-klib-reader" breaks JPS compilation
  • KT-66603 Analysis API: support type annotations in KtPsiTypeProviderMixIn#asPsiType
  • KT-64505 Analysis API Standalone: Remove test-specific calculation of sealed class inheritors
  • KT-66013 Analysis API Standalone: Sealed inheritors aren't correctly calculated for source classes
  • KT-62880 K2 IDE: Unresolved java annotation methods in KDoc
  • KT-66530 K2: Analysis API: KtPsiTypeProvider#asKtType crashes on PsiClassType for Java type parameter with wrong use site
  • KT-65571 Support VirtualFile inputs to Analysis API modules
  • KT-66485 Substituted types are not provided for callable references
  • KT-66498 Analysis API: 'KtFe10SymbolDeclarationOverridesProvider' considers a class to be a subclass of itself
  • KT-64579 K2 IDE: "Expected FirResolvedArgumentList for FirAnnotationCallImpl of FirValueParameterImpl(Source) but FirArgumentListImpl found"
  • KT-65978 Analysis API: Use soft references in FileStructureCache
  • KT-64051 K2 IDE: Analysis API: Unresolved links to typealias in KDoc
  • KT-66189 K2 / IDE: KtFirExpressionTypeProvider bugs
  • KT-61422 K2 IDE: "No array element type for vararg value parameter: org.jetbrains.kotlin.fir.declarations.impl.FirValueParameterImpl"
  • KT-66276 K2: Analysis API: TYPECHECKER_HAS_RUN_INTO_RECURSIVE_PROBLEM false positive for script parameter
  • KT-66232 K2: Analysis API: cover ScriptWithCustomDefDiagnosticsTestBaseGenerated by LL FIR tests
  • KT-60996 K2: Stub Based Deserializer: Set versionRequirements to enable VERSION_REQUIREMENT_DEPRECATION diagnostics
  • KT-66306 K2: Analysis API: drop ability to enable global phase resolve lock
  • KT-55750 LL FIR: Implement multi-threaded resolve
  • KT-65563 Analysis API: Missing session component FirExpectActualMatchingContextFactory in LLFirLibrarySession
  • KT-66173 K2: No 'org.jetbrains.kotlin.fir.scopes.impl.FirDelegatedMembersFilter' in array owner: LLFirLibrarySession
  • KT-66238 Gradle kotlin build scripts - a lot of unresolved symbols after latest changes in kotlin master
  • KT-65099 K2: Recursive local storage cache check for Fir2IrDeclarationStorage::createAndCacheIrPropertySymbols()
  • KT-65265 Analysis API: Add library session invalidation tests
  • KT-56288 Analysis API: Add tests for session invalidation on the Analysis API side
  • KT-64000 K2: make AnnotationArgumentsStateKeepers more accurate
  • KT-63606 K2: Analysis API: rewrite FirLazyAnnotationTransformer to avoid redundant transformations
  • KT-65191 KtFirMultiplatformInfoProvider#getExpectForActual doesn't return expect function for slightly broken code
  • KT-62136 Analysis API: Add concurrent tests for CleanableSoftValueCache
  • KT-61222 K2: Add lifecycle management for KtResolveExtension
  • KT-65960 Analysis API: Test infrastructure indexes binary libraries from decompiled files instead of stubs during IDE mode tests
  • KT-65240 K2: CodeGen API fails to resolve Annotation parameter type when it runs FIR2IR for a class with a parent class from other module if the parent class has an annotation from another module
  • KT-65344 K2: make FirScript statements (declarations) independent
  • KT-65930 AA: receiver type for Int?::foo misses nullability
  • KT-65914 AA: receiver type for this::foo returns return type of the target callable
  • KT-62071 Analysis API: KtFirScopeProvider.getScopeContextForPosition throws exception when ImplicitReceiverValue.implicitScope is null
  • KT-65780 K2: polish FileStructure implementation for FirFile
  • KT-62840 K2 Script: everything around destructuring declaration on top level of scripts are broken
  • KT-64528 K2 IDE: MPP: unregistered component 'org.jetbrains.kotlin.fir.scopes.impl.FirDelegatedMembersFilter'
  • KT-64921 K2 IDE: references in platform code resolve to expect classifier instead of actual
  • KT-61296 K2: do not resolve the entire file on lazyResolve call if FirFile is passed
  • KT-65683 Analysis API: Dangling file session creation causes a computeIfAbsent contract violation
  • KT-64884 K2 IDE. FP [NAMED_PARAMETER_NOT_FOUND] for copy method of library data class when class has not parameter-properties
  • KT-65763 K2: value parameter from library data class copy have RAW_FIR phase
  • KT-65665 Analysis API: support KtDelegatedSuperTypeEntry in KtFirExpressionInfoProvider.isUsedAsExpression
  • KT-62899 K2 IDE. IDE ignores @Suppress annotation for errors
  • KT-65655 Analysis API: KtCodeCompilationException should not strongly reference FIR sessions
  • KT-62302 Support PsiType -> KtType conversion
  • KT-64604 K2: IDE K2: "Modules are inconsistent during performance tests"
  • KT-65345 K2: unify FirDesignation and ...
Read more