Releases: JetBrains/kotlin
Releases · JetBrains/kotlin
1.2-RC2
Compiler
KT-20844
VerifyError on Android after upgrading to 1.2.0-beta-88KT-20895
NPE in Kotlin 1.2-beta88 PseudocodeVariablesData.kt:337KT-21377
Create fallback flag for "Illegal smart cast is allowed after assignment in try block"
IDE
KT-18719
Configure Kotlin in Gradle project to 1.2-Mx: add repository mavenCentral() to buildscriptKT-20782
Exception when working with routing in ktor (non-atomic trees update)KT-20966
ISE: Facade class not found from Kotlin test filesKT-20967
Kotlin plugin upgrade breaks Gradle refreshKT-20990
String literal in string template causes ISEKT-21028
Add kotlin-stdlib-jre7/8 instead of kotlin-stdlib-jdk7/8 for Kotlin versions below 1.2KT-21383
Unsupported method: Library.getProject()
when importing Anko project- Downgrade "use expression body" inspection to INFORMATION default level
IDE. Debugger
KT-20962
NullPointerException because of nullable location in debugger
IDE. Inspections and Intentions
KT-20803
Create actual declaration in the same source root as expect declaration
IDE. Refactorings
KT-20979
Move class refactoring doesn't work anymore
Libraries
- Remove deprecated
pairwise
function
Tools. Gradle
KT-21395
“Unable to load class 'kotlin.collections.CollectionsKt'” on creating gradle project in IDEA 2016.3.7
Tools. kapt
- Add
kotlin-annotation-processing-embeddable
artifact (compatible withkotlin-compiler-embeddable
) - Return
kotlin-annotation-processing
artifact back (compatible with CLI Kotlin compiler)
Previous releases
This release also includes the fixes and improvements from the previous
1.2-RC1
release.
1.1.60
- Adds experimental support for Kotlin/JS incremental compilation
- Adds new features to JSR-305 custom nullability annotations support
- Brings a lot of bug fixes in the automatic Parcelable implementation generator and provides it with IDE support
- Improves Gradle incremental builds
- Introduces new inspections, performance improvements and bug fixes in the IntelliJ plugin
The complete list of changes in this release can be found in the changelog.
The update is compatible with all versions of IntelliJ IDEA from 2016.3 until 2017.3, as well as with Android Studio 2.3, 3.0 and 3.1 Canary.
1.2-RC
Compiler
Fixes
KT-20774
"::foo.isInitialized" for lateinit member properties produces incorrect bytecodeKT-20826
Can't compile Ultimate Idea with Kotlin 1.2KT-20879
Compiler problem in when-expressionsKT-20959
Regression: Unexpected diagnostic NINITIALIZED_ENUM_COMPANION reported in 1.1.60 & 1.2.0-rcKT-20651
Don't know how to generate outer expression" for enum-values with non-trivial self-closures
IDE
New Features
KT-20286
"Configure Kotlin in project" should add kotlin-stdlib-jdk7/8 instead of kotlin-stdlib-jre7/8 starting from Kotlin 1.2
Fixes
KT-19599
No indentation for multiline collection literalKT-20346
Can't build tests in common code due to missing org.jetbrains.kotlin:kotlin-test-js testCompile dependency in JSKT-20550
Spring: "Navigate to autowired candidates" gutter action is missed (IDEA 2017.3)KT-20566
Spring: "Navigate to the spring beans declaration" gutter action for@ComponentScan
is missed (IDEA 2017.3)KT-20843
Kotlin TypeDeclarationProvider may stop other declarations providers executionKT-20906
Find symbol by name doesn't workKT-20920
UAST: SOE Thrown in JavaColorProviderKT-20922
Couldn't match ClsMethodImpl from Kotlin test filesKT-20929
Import Project from Gradle wizard: the same page is shown twiceKT-20833
MP project: add dependency to kotlin-test-annotation-common to common module
IDE. Completion
KT-18458
Spring: code completion does not suggest bean names inside@Qualifier
before function parameter
IDE. Inspections and Intentions
KT-20899
Code Cleanup fails to convert Circlet codebase to 1.2KT-20949
CCE from UAST (File breadcrumbs don't update when file tree does)
IDE. Refactorings
KT-20251
Kotlin Gradle script: Refactor → Inline works incorrect when you need to inline all function occurrences
JavaScript
KT-2976
Suggestion for cleaner style to implement !! operatorKT-5259
JS: RTTI may be break by overwriting constructor fieldKT-17475
JS: object and companion object named "prototype" cause exceptionsKT-18095
JS: Wrong behavior of fun named "constructor"KT-18105
JS: inner class "length" cause runtime exceptionKT-20625
JS: Interface function with default parameter, overridden by other interface cannot be found at runtimeKT-20820
JS: IDEA project doesn't generate paths relative to .map
Libraries
KT-4900
Finalize math operation parameter names
Tools. JPS
KT-20852
IllegalArgumentException: URI has an authority component on attempt to jps compile the gradle project with javascript module
Tools. kapt
KT-20877
Butterknife: UninitializedPropertyAccessException: "lateinit property has not been initialized" for field annotated with@BindView
.
Previous releases
This release also includes the fixes and improvements from the previous
1.2-Beta2
release.
1.1.60-eap-43
What's new
- Bug fixes and further improvements in support for JSR-305 nullability annotations:
- Type qualifier defaults can now be used with
ElementType.TYPE_USE
to provide nullability information for types in all positions including type arguments, upper bounds of type parameters and wildcard types - Migration status of custom nullability annotations can be controlled with the
@UnderMigration
annotation (packaged in a new artifactkotlin-annotations-jvm
) - Support for fine-grained migration status control on the library user side with the compiler configuration flag
-Xjsr305
- Type qualifier defaults can now be used with
- Experimental support for Kotlin/JS incremental compilation in Gradle builds; it is disabled by default and can be enabled by setting
kotlin.incremental.js = true
ingradle.properties
orlocal.properties
- Bug fixes in
Parcelable
implementation generation with@Parcelize
- Lots of bug fixes in the compiler and IDE
- New inspections, performance improvements and bugfixes in the IntelliJ plugin
- Other improvements in support for Gradle incremental builds
1.2-Beta2
CHANGELOG
1.2-Beta2
Multiplatform projects
New Features
KT-20616
Compiler options forKotlinCompileCommon
taskKT-15522
Treat expect classes without explicit constructors as not having constructors at allKT-16099
Do not require obvious override of super-interface methods in non-abstract expect classKT-20618
Renameimplement
toexpectedBy
in gradle module dependency
Fixes
KT-16926
'implement' dependency is not transitive when importing gradle project to IDEAKT-20634
False error about platform project implementing non-common projectKT-19170
Forbid private expected declarationsKT-20431
Prohibit inheritance by delegation in 'expect' classesKT-20540
Report errors about incompatible constructors of actual classKT-20398
Do not highlight declarations with not implemented implementations with red during typingKT-19937
Support "implement expect class" quickfix for nested classesKT-20657
Actual annotation with all parameters that have default values doesn't match expected annotation with no-arg constructorKT-20680
No actual class member: inconsistent modality checkKT-18756
multiplatform project: compilation error on implementation of extension property in javascript client moduleKT-17374
Too many "expect declaration has no implementation" inspection in IDE in a multi-platform projectKT-18455
Multiplatform project: show gutter Navigate to implementation on expect side of method in the expect classKT-19222
Useless tooltip on a gutter icon for expect declarationKT-20043
multiplatform: No H gutter if a class has nested/inner classes inherited from itKT-20164
expect/actual navigation does not work when actual is a typealiasKT-20254
multiplatform: there is no link between expect and actual classes, if implementation has a constructor when expect doesn'tKT-20309
multiplatform: ClassCastException on mouse hovering on the H gutter of the actual secondary constructorKT-20638
Context menu in common module: NSEE: "Collection contains no element matching the predicate." at KotlinRunConfigurationProducerKt.findJvmImplementationModule()KT-18919
multiplatform project: expect keyword is lost on converting to objectKT-20008
multiplatform: Create expect class implementation should add actual keyword at secondary constructorsKT-20044
multiplatform: Create expect class implementation should add actual constructor at primary constructorKT-20135
"Create expect class implementation" should open created class in editorKT-20163
multiplatform: it should be possible to create an implementation for overloaded method if for one method implementation is present alreadyKT-20243
multiplatform: quick fix Create expect interface implementation should add actual keyword at interface membersKT-20325
multiplatform: Quick fix Create actual ... should specify correct classifier name for object, enum class and annotation class
Compiler
New Features
KT-16028
Allow to have different bodies of inline functions inlined depending on apiVersion
Performance Improvements
KT-20462
Don't create an array copy for '*(...)'
Fixes
KT-13644
Information from explicit cast should be used for type inferenceKT-14697
Use-site targeted annotation is not correctly loaded from class fileKT-17981
Type parameter for catch parameter possible when exception is nested in generic, but fails in runtimeKT-19251
Stack spilling in constructor arguments breaks QuasarKT-20387
Wrong argument generated for accessor call of a protected generic 'operator fun get/set' from base class with primitive type as type parameterKT-20491
Incorrect synthetic accessor generated for a generic base class function specialized with primitive typeKT-20651
"Don't know how to generate outer expression" for enum-values with non-trivial self-closuresKT-20752
Do not register new kinds of smart casts for unstable values
IDE
New Features
KT-19146
Parameter hints could be shown for annotation
Fixes
KT-19207
"Configure Kotlin in project" should add "requires kotlin.stdlib" to module-info for Java 9 modulesKT-19213
Formatter/Code Style: space between type parameters andwhere
is not insertedKT-19216
Parameter name hints should not be shown for functional type invocationKT-20448
Exception in UAST during reference search in J2KKT-20543
java.lang.ClassCastException on usage of array literals in Spring annotationKT-20709
Loop in parent structure when converting a LITERAL_STRING_TEMPLATE_ENTRY
IDE. Completion
KT-17165
Support array literals in annotations in completion
IDE. Debugger
KT-18775
Evaluate expression doesn't allow access to properties of private nested objects, including companion
IDE. Inspections and Intentions
New Features
KT-20108
Support "add requires directive to module-info.java" quick fix on usages of non-required modules in Kotlin sourcesKT-20410
Add inspection for listOf().filterNotNull() to replace it with listOfNotNull()
Fixes
KT-16636
Remove parentheses after deleting the last unused constructor parameterKT-18549
"Add type" quick fix adds non-primitive Array type for annotation parametersKT-18631
Inspection to convert emptyArray() to empty literal does not workKT-18773
Disable "Replace camel-case name with spaces" intention for JS and common projectsKT-20183
AE “Classifier descriptor of a type should be of type ClassDescriptor” on adding element to generic collection in functionKT-20315
"call chain on collection type may be simplified" generates code that does not compile
JavaScript
Fixes
KT-8285
JS: don't generate tmp when only need one componentKT-8374
JS: some Double values converts to Int differently on JS and JVMKT-14549
JS: Non-local returns from secondary constructors don't workKT-15294
JS: parse error injs()
functionKT-17629
JS: Equals function (==) returns true for all primitive numeric typesKT-17760
JS: Nothing::class throws errorKT-17933
JS: toString, hashCode method and simplename property of KClass return senseless results for some classesKT-18010
JS: JsName annotation in interfaces can cause runtime exceptionKT-18063
Inlining does not work properly in JS for suspend functions from another moduleKT-18548
JS: wrong string interpolation with generic or Any parametersKT-19772
JS: wrong boxing behavior for...
1.2-Beta
Android
New Features
KT-20051
Quickfixes to support @parcelize
Fixes
KT-19747
Android extensions + Parcelable: VerifyError in case of RawValue annotation on a type when it's unknown how to parcel itKT-19899
Parcelize: Building with ProGuard enabledKT-19988
[Android Extensions] inner class LayoutContainer causes NoSuchMethodErrorKT-20002
Parcelize explodes on LongArrayKT-20019
Parcelize does not propogate flags argument when writing nested ParcelableKT-20020
Parcelize does not use primitive array read/write methods on ParcelKT-20021
Parcelize does not serialize Parcelable enum as ParcelableKT-20022
Parcelize should dispatch directly to java.lang.Enum when writing an enum.KT-20034
Application installation failed (INSTALL_FAILED_DEXOPT) in Android 4.3 devices if I use ParcelizeKT-20057
Parcelize should use specialized write/create methods where available.KT-20062
Parceler should allow otherwise un-parcelable property types in enclosing class.KT-20170
UAST: Getting the location of a UIdentifier is tricky
Compiler
KT-4565
Support smart casting of safe cast's subject (and also safe call's receiver)KT-8492
Null check should work after save call with elvis in conditionKT-9327
Need a way to check whether a lateinit property was assignedKT-14138
Allow lateinit local variablesKT-15461
Allow lateinit top level propertiesKT-7257
NPE when accessing properties of enum from inner lambda on initializationKT-9580
Report an error if 'setparam' target does not make sense for a parameter declarationKT-16310
Nested classes inside enum entries capturing outer membersKT-20155
Confusing diagnostics on a nested interface in inner class
IDE
KT-14175
Surround with try ... catch (... finally) doesn't work for expressionsKT-20308
New Gradle with Kotlin DSL project wizardKT-18353
Support UAST for .kts filesKT-19823
Kotlin Gradle project import into IntelliJ: import kapt generated classes into classpathKT-20185
Stub and PSI element type mismatch for "var nullableSuspend: (suspend (P) -> Unit)? = null"
Language design
KT-14486
Allow smart cast in closure if a local variable is modified only before it (and not after or inside)KT-15667
Support "::foo" as a short-hand syntax for bound callable reference to "this::foo"KT-16681
kotlin allows mutating the field of read-only property
Libraries
KT-19258
Java 9: module-info.java withrequires kotlin.stdlib
causes compiler to fail: "module reads package from both kotlin.reflect and kotlin.stdlib"
Tools
KT-19692
kotlin-jpa plugin doesn't support @MappedSuperclass annotationKT-20030
Parcelize can directly reference writeToParcel and CREATOR for final, non-Parcelize Parcelable types in same compilation unit.KT-19742
[Android extensions] Calling clearFindViewByIdCache causes NPEKT-19749
Android extensions + Parcelable: NoSuchMethodError on attempt to pack into parcel a serializable objectKT-20026
Parcelize overrides describeContents despite being already implemented.KT-20027
Parcelize uses wrong classloader when reading parcelable type.KT-20029
Parcelize should not directly reference parcel methods on types outside compilation unitKT-20032
Parcelize does not respect type nullability in case of Parcelize parcelables
Tools. CLI
KT-10563
Support a command line argument -Werror to treat warnings as errors
Tools. Gradle
KT-20212
Cannot access internal components from test code
Tools. kapt
KT-17923
Reference to Dagger generated class is highlighted redKT-18923
Kapt: Do not use the Kotlin error message collector to issue errors from kaptKT-19097
Request: Decent support ofkapt.kotlin.generated
on Intellij/Android StudioKT-20001
kapt generate stubs Gradle task does not depend on the compilation of sub-project kapt dependencies
1.1.51
1.1.50
Android
KT-14800
Kotlin Lint:@SuppressLint
annotation on local variable is ignoredKT-16600
False positive "For methods, permission annotation should specify one ofvalue
,anyOf
orallOf
"KT-16834
Android Lint: Bogus warning on @SetParam:StringResKT-17785
Kotlin Lint: "Incorrect support annotation usage" does not pick the value of const valKT-18837
Android Lint: Collection.removeIf is not flagged when used on RealmListKT-18893
Android support annotations (ColorInt, etc) cannot be used on properties: "does not apply for type void"KT-18997
KLint: False positive "Could not find property setter method setLevel on java.lang.Object" if using elvis with return on RHSKT-19671
UAST: Parameter annotations not provided for val parameters
Compiler
Performance Improvements
KT-17963
Unnecessary boxing in case of primitive comparison to objectKT-18589
'Equality check can be used instead of elvis' produces code that causes boxingKT-18693
Optimize in-expression with optimizable range in RHSKT-18721
Improve code generation for if-in-primitive-literal expression ('if (expr in low .. high)')KT-18818
Optimize null cases inwhen
statement to avoid Intrinsics usageKT-18834
Do not create ranges for 'x in low..high' where type of x doesn't match range element typeKT-19029
Use specialized equality implementations for 'when'KT-19149
Use 'for-in-until' loop in intrinsic array constructorsKT-19252
Use 'for-in-until' loop for 'for-in-rangeTo' loops with constant upper bounds when possibleKT-19256
Destructuring assignment generates redundant code for temporary variable nullificationKT-19457
Extremely slow analysis for file with deeply nested lambdas
Fixes
KT-10754
Bogus unresolved extension functionKT-11739
Incorrect error message on getValue operator with KProperty parameterKT-11834
INAPPLICABLE_LATEINIT_MODIFIER is confusing for a generic type parameter with nullable (default) upper boundKT-11963
Exception: recursive call in a lazy value under LockBasedStorageManagerKT-12737
Confusing error message when calling extension function with an implicit receiver, passing value parameter of wrong typeKT-12767
Too much unnecessary information in "N type arguments expected" error messageKT-12796
IllegalArgumentException on referencing inner class constructor on an outer class instanceKT-12899
Platform null escapes if passed as an extension receiver to an inline functionKT-13665
Generic componentN() functions should provide better diagnostics when type cannot be inferredKT-16223
Confusing diagnostic for local inline functionsKT-16246
CompilationException caused by intersection type overload and wrong type parameterKT-16746
DslMarker doesn't work with typealiasesKT-17444
Accessors generated for private file functions should respect @JvmNameKT-17464
Calling super constructor with generic function call in arguments fails at runtimeKT-17725
java.lang.VerifyError when both dispatch receiver and extension receiver have smart castsKT-17745
Unfriendly error message on creating an instance of interface via typealiasKT-17748
Equality for class literals of primitive types is not preserved by reificationKT-17879
Comparing T::class from a reified generic with a Class<> and KClass<> variable in when statement is brokenKT-18356
Argument reordering in super class constructor call for anonymous object fails with VerifyErrorKT-18819
JVM BE treats 'if (a in low .. high)' as 'if (a >= low && a <= high)', so 'high' can be non-evaluatedKT-18855
Convert "Remove at from annotation argument" inspection into compiler error & quick-fixKT-18858
Exception within typealias expansion with dynamic used as one of type argumentsKT-18902
NullPointerException when using provideDelegate with properties of the base class at runtimeKT-18940
REPEATED_ANNOTATION is reported on wrong location for typealias argumentsKT-18944
Type annotations are lost for dynamic typeKT-18966
Report full package FQ name in compilation errors related to visibilityKT-18971
Missing non-null assertion for platform type passed as a receiver to the member extension functionKT-18982
NoSuchFieldError on access to imported object property from the declaring object itselfKT-18985
Too large highlighting range for UNCHECKED_CASTKT-19058
VerifyError: no CHECKAST on dispatch receiver of the synthetic property defined in Java interfaceKT-19100
VerifyError: missing CHECKCAST on extension receiver of the extension propertyKT-19115
Report warnings on usages of JSR 305-annotated declarations which rely on incorrect or missing nullability informationKT-19128
java.lang.VerifyError with smart cast to String from AnyKT-19180
Bad SAM conversion of Java interface causing ClassCastException: [...] cannot be cast to kotlin.jvm.functions.Function1KT-19205
Poor diagnostic message for deprecated class referenced through typealiasKT-19367
NSFE if property with name matching companion object property name is referenced within lambdaKT-19434
Object inheriting generic class with a reified type parameter looses method annotationsKT-19475
AnalyserException in case of combination ofwhile (true)
+ stack-spilling (coroutines/try-catch expressions)KT-19528
Compiler exception on inline suspend function inside a generic classKT-19575
Deprecated typealias is not marked as such in access to companion objectKT-19601
UPPER_BOUND_VIOLATED reported on type alias expansion in a recursive upper bound on a type parameterKT-19814
Runtime annotations for open suspend function are not generated correctlyKT-19892
Overriding remove method on inheritance from TreeSetKT-19910
Nullability assertions removed when inlining an anonymous object in crossinline lambdaKT-19985
JSR 305: nullability qualifier of Java function return type detected incorrectly in case of using annotation nickname
IDE
New Features
KT-6676
Show enum constant ordinal in quick doc like in JavaKT-12246
Kotlin source files are not highlighted in Gradle build output in IntelliJ
Performance Improvements
KT-19670
When computing argument hints, don't resolve call if none of the arguments are unclear expressions
Fixes
KT-9288
Call hierarchy ends on function call inside local val initializer expression- [
KT-9669
](https://youtrack.jetbrains.com/is...
1.1.4-3
KT-18062
SamWithReceiver compiler plugin not used by IntelliJ for .kt filesKT-18497
Gradle Kotlin Plugin does not work with the gradle java-library pluginKT-19276
Console spam when opening idea-community project in debug IDEAKT-19433
[Coroutines + Kapt3] Assertion failed in ClassClsStubBuilder.createNestedClassStubKT-19680
kapt3 & Parcelize: Compilation errorKT-19687
Kotlin 1.1.4 noarg plugin breaks with sealed classesKT-19700
Kapt error after updating to 1.1.4 - stub adds type parameters where there are noneKT-19713
Mocking of final named suspend methods with mockito failsKT-19729
kapt3: not always including argument to @javax.inject.Named in generated stubsKT-19759
"Convert to expression body" is not shown in 162 / AS23 branches for multi-linersKT-19767
NPE caused by Map<String, Boolean>?.getKT-19769
PerModulePackageCacheService calls getOrderEntriesForFile() for every file, even those that can't affect Kotlin resolveKT-19774
Provide an opt-out flag for separate classes directories (Gradle 4.0+)KT-19847
if an imported library already exists it should be redetected during gradle import
1.1.4-2
KT-19679
CompilationException: Couldn't inline method call 'methodName' into...KT-19690
Lazy field in interface default method leads to ClassFormatErrorKT-19716
QuickdocCtrl+Q
broken while browsing code completion listCtrl-Space
KT-19717
Library kind incorrectly detected for vertx-web in Kotlin projectKT-19723
"Insufficient maximum stack size" during compilation