How has Kotlin/Native 1.5.20 improved compiler bug fixes?
Kotlin 1.5.20
Kotlin continues to stay up to date and updates and fixes the issues in Kotlin 1.5.0. Kotlin 1.5.20 has been released, and makes improvements in Java features and support.
The following are some of the updates and fixes in Kotlin 1.5.20.
-
Kotlin/JVMimprovements. -
Kotlin/Nativeimprovements. -
Kotlin/JSIR backend migration guide. -
Gradle improvements. Standard library improvements.
Improvements in Kotlin/Native
A lot of significant changes have been made in Kotlin 1.5.20. However, an essential bug fix is made that affects compatibility.
In the previous versions of Kotlin, the string constants with the incorrect
It is safe for app developers to update to 1.5.20. However, libraries compiled with 1.5.20 are not compatible with previous compiler versions of Kotlin.
Changelog updates in Kotlin 1.5.20
The following is the list of changes and updates related to Kotlin/Native 1.5.20.
Compiler
1. New features
New features introduced to the Kotlin/Native 1.5.20 Compiler are:
-
No error in Java generic class. With the nullable type argument in
Kotlin, the@NotNulltype parameter is utilized. -
Support error/warning suppression.
-
Support nullability annotations at the module level.
-
No warnings based on
jspecifyannotations. -
Allow
JvmInlineannotation to be omitted for expected value classes. -
For
-jvm-target 1.8and above, does not declare footnotes on function type parameters into bytecode.
2. Performance improvements
- Don’t box primitive values inequality comparison with objects in
JVM_IR.
3. Fixes
Some of the fixes related to the Kotlin/Native 1.5.20 Compiler are listed below.
- Unresolved annotation should be an error.
- Type annotation remained unsolved in an unknown object expression on a type parameter of a supertype.
-
Restrain the use of a type parameter associated with an extension property within a delegate.
-
Interpretation of annotation on return types and supertypes is not made.
-
Annotation mark is not interpreted in some instances for type annotations.
-
Prevent unsafe calls with expected
@NotNull Tand presentedKotlingeneric parameter includingnullable bound. -
For
Kotlin/Native IR: Remapping of reference to expect characteristics in the actual declaration is not done. -
Kotlin/Native: In general, the IR backend module’sIrProperty.overriddensymbols still can’t be used, as it does not function fully inNative. -
Native: WhenInt.MIN_VALUEis divided by -1, it either hangs or crashes.
IDE - Native
- Reduced memory consumption
1. Native. C Export
- Error can occur when packages without public methods produce an empty struct in the header.
2. Native. ObjC Export
-
kdoccomments are not a part ofKotlinMP iOS Target. -
KMM: hard to pass an error toKotlincode from implementingKotlinmethod inSwiftcode.
3. Native. Runtime. Memory
- Profiling shows that when KMP code is operated, a lot of time is consumed on
updateHeapRefon Apple platforms.
4. Tools. Gradle. Native.
-
In MPP Gradle plugin, a framework packing task for
Kotlin/Nativeis presented. -
When the download process is stopped,
stdlibis missing.
For a detailed list of changes and working, visit the changelog.