Info about particular features
New project templates in Kotlin/JS:
KT-41417
- Add react template to new project wizardKT-40527
- Node.JS application template in New Project WizardKT-35549
- Support kotlin-android-extensions in JVM IR backend (for use with Jetpack Compose projects)
Kotlin/JS Gradle plugin upgrades:
Performance boosts:
Changelog
Backend. Native
KT-27534
Bridges to Nothing-returning methods have incorrect signatureKT-30284
Native: Nothing? type for expression override and crashKT-36430
Optimize when with in range casesKT-38787
Missing optimization for "in range" checkKT-39100
Make Native behaviour of property initialization consistent with JVMKT-39798
Override equals/hashCode in functional interface wrappers on NativeKT-39800
equals/hashCode on adapted function references on NativeKT-41394
Compilation failed: Backend Internal error: Exception during IR loweringKT-41907
Framework test segfaults on GC on watchos_x86 compiled with -opt
Compiler
New Features
KT-35549
Support kotlin-android-extensions in JVM IR backend (for use with Jetpack Compose projects)
Performance Improvements
KT-20571
Coroutines: Reduce number of local variables stored at suspension pointKT-28016
Coroutine state-machines spill/unspill shall be optimized using data-flow analysisKT-33394
UI freezes triggered by QualifiedExpressionResolver.resolveToPackageOrClassPrefixKT-36814
Support optimized delegated properties in JVM_IRKT-36829
Optimize 'in' expressions (operator fun contains) in JVM_IR
Fixes
KT-16222
Coroutine should be clearing any internal state as soon as possible to avoid memory leaksKT-25519
Extra inline marks inside suspending function callable reference bytecodeKT-33226
Object INSTANCE field not annotated with NotNull in generated bytecodeKT-35495
FIR: forbid non-Java synthetic propertiesKT-35651
Kotlin stdlib has greater resolution priority than jars added via @file:DependsOn annotationKT-35730
FIR: consider creating fake overrides for objectsKT-36951
IllegalStateException: Expected some types: Throwing exception when there is a type parameter upper bound for itselfKT-37321
[FIR] Support java array in type argumentKT-37431
[FIR] Support Builder InferenceKT-38272
FIR2IR: use lazy IR symbols for externals & fake overridesKT-38333
FIR: CCE on red code with assignment used as expressionKT-38334
FIR: CCE when resolving try-as-expressionKT-38336
FIR: NPE with corrupted numeric constant literalKT-38397
FIR: Exception while resolving contract definitionKT-38444
[FIR] Invoke extension lambda with safe callKT-38470
FIR: ConeDefinitelyNotNullType in signatureKT-38471
FIR: ConeIntersectionType in signatureKT-38925
Internal error: wrong bytecode generated. (AssertionError: int type expected, but null was found in basic frames)KT-38989
FIR: Refine sealed classes exhaustiveness in case of sealed subclassKT-38992
FIR: Refine type resolution for inner classesKT-39000
FIR: Support smartcast after reference equality checkKT-39005
FIR: Resolve plusAssign in a dependent contextKT-39008
FIR: Investigate strange effect of type alias and not-nullable bound on inferenceKT-39012
FIR: Inference doesn't get through elvis to lambda parameterKT-39028
FIR: Strange resolution to synthetic property with implicit extension receiver while there's an explicit receiverKT-39032
FIR: Ambiguity in member scope of a type parameter with multiple boundsKT-39033
FIR: Ambiguity when calling generic overridden propertyKT-39034
FIR: Support nested extension function typesKT-39040
FIR: Deserialize annotations from compiled Kotlin binariesKT-39043
FIR: Bare types incorrectly work with type aliasesKT-39044
FIR: Add fillInStackTrace to member scope of kotlin.ThrowableKT-39046
FIR: Implicit types in lambdas left when call argument is a type castKT-39048
FIR: Inference fails with integer literal used as ComparableKT-39050
FIR: Type resolver doesn't see nested classes from super class of a local classKT-39070
FIR: Ambiguity on super calls to hashCode/equals when having super interface and classKT-39072
FIR: Subtyping check doesn't affect nullability of safe-call receiverKT-39076
FIR: Synthetic property is not a var because of @nullable annotation on parameterKT-39080
FIR: Smart casts remain incorrect if lambda is present in when branchKT-39374
Wrong bytecode generated for suspend function call with EXACTLY_ONCE lambda capturing a variable initialized in when-subjectKT-39621
[FIR] Support when exhaustiveness checker for java enumsKT-40135
JVM IR does not generate restricted suspend lambdasKT-40382
Missing proper jvmSignature for synthesized equals/hashCode/toString in inline classesKT-40605
JVM IR: IndexOutOfBoundsException caused by inner class passed to generic outer class method with Nothing type argumentKT-40664
JVM: No bounds check in optimization ofULong in UInt..UInt
KT-40665
JVM: No resolved function check when optimizingin/contains
with mismatched bound typesKT-41014
FIR2IR: when/where/how to determine the presence of a backing field for a propertyKT-41018
FIR2IR: sort members during de/serializationKT-41144
False positive "Redundant spread operator" in when statement and generic vararg argumentKT-41374
JVM / IR: NoSuchMethodError in Android project compiler caused by combination of inline classes and coroutinesKT-41388
NI: Backend Internal error: Exception during IR loweringKT-41429
Inline class returned from suspend function should be boxed on resume pathKT-41465
JVM / IR: "AssertionError: inconsistent parent function for CLASS LAMBDA_IMPL CLASS name" caused by inline method call into multiple constructorsKT-41668
JVM IR: incorrect enclosing constructor for lambdas in initializers of inner classesKT-41669
JVM IR: incorrect hashCode intrinsic is used in JVM target 1.8 for generic type substituted with primitiveKT-41693
NI: Type inference in nested expression incorrectly assumes non-nullable return type of Java function, causing NullPointerExceptionKT-41729
NI: UnsupportedOperationException with invalid callable referenceKT-41761
JVM IR: CCE from backend on generating typeOf for non-reified type parameter with star projection in upper boundKT-41789
Missing DebugMetadata in inlined suspend lambdaKT-41913
NI: Kotlin 1.4 type inference breaks valid codeKT-41934
NI: a type variable for lambda parameter has been inferred to nullable type instead of not null one
IDE
New Features
KT-20775
More kotlin kinds in new kotlin file/class menuKT-31331
Improve: Optimize Import should remove unused unresolved importsKT-31500
Smart enter: support get() clauseKT-39231
Injection: Add receiver of kotlin.text.toPattern to standard Kotlin injectionsKT-39844
Add specific highlight for Enum class
Performance Improvements
KT-39353
Implement EnterBetweenBracesNoCommitDelegateKT-39720
A lot of freezes in Kotlin projectKT-41634
Deadlock in org.jetbrains.kotlin.idea.framework.LibraryEffectiveKindProviderImpl.getEffectiveKindKT-41936
Impossible to work with Kotlin 1.4 in 202 idea, idea eats all cpu
Fixes
KT-10790
"Move statement up" for @file-targeted annotation moves package declaration to bottom of fileKT-15262
"Generate toString()" is ignoring property if it has a getterKT-24352
Method separators: displayed between properties, not displayed between companion object and functionKT-29364
"Extend selection" can't select lambda body with parametersKT-32403
Clickable links in annotation parameters (like in TODOs)KT-32409
Organizing imports should not remove imports while there are unresolved symbolsKT-33131
No indent before get/set method while editing extension var declarationKT-34566
Too small indent after line break for multi line stringsKT-34587
"Move statement down" doesn't work for statement in constructor with end-of-line commentKT-34705
"Move statement down" for penultimate statement with end-of-line comment in constructor leads to moving comma to the end of commentKT-34707
"Move statement up" for last statement with end-of-line comment in constructor leads to moving comma to the end of commentKT-35424
FIR IDE: Kotlin project does not see stdlibKT-35732
URLs in String literals are not clickableKT-35859
Language injection doesn't work with named arguments in different positionKT-37210
UAST: KtLightClassForSourceDeclaration.isInheritor sometimes returns the wrong resultKT-37219
File level OptIn annotation is not recognized by the IDEKT-39398
Wrong import of unrelated object member is suggested for receiverKT-39457
Separate decompiled declarations Light implementation from LightClasses infrastructureKT-39899
KotlinOptimizeImportsRefactoringHelper: ISE: Attempt to modify PSI for non-committed DocumentKT-40578
UAST: write accesses to Kotlin properties should resolve to setterKT-41290
KotlinClassViaConstructorUSimpleReferenceExpression resolves to PsiMethod instead of PsiClassKT-42029
HMPP, IDE: NPE fromFacetSerializationKt.getFacetPlatformByConfigurationElement
on project opening
IDE. Completion
KT-26235
Kotlin methods/fields don't have icons in Java completion
IDE. Debugger
KT-39309
Debugger: Prolonged "Collecting data" for variables when breakpoint is insiderespondHtml
KT-39435
"Collecting data..." in debugger variables view never finishesKT-39717
Debugger shows "Collecting data..." forever for instances of some classKT-40386
Memory leak detected: 'org.jetbrains.kotlin.idea.debugger.coroutine.view.XCoroutineView'KT-41505
Coroutines Debugger: “Access is allowed from event dispatch thread with IW lock only.”
IDE. Gradle Integration
KT-34271
SupportpureKotlinSourceFolders
for MPP projectsKT-37106
Gradle + IDE integration: on creating source roots from Project tree IDEA creates incorrect settings
IDE. Gradle. Script
KT-35092
“Unable to get Gradle home directory” popup and no build.gradle.kts highlighting right after creating a new projectKT-37590
Wrong notification for precompiled build scriptKT-39523
Go to Declaration navigates to decompiled classfile instead of sources in case of jumping to Gradle plugin sources in buildSrcKT-39790
List of standalone script should be saved between IDE restartsKT-39910
build.gradle.kts isn't highlighted after importKT-39916
init.gradle.kts isn't highlightedKT-40243
gradle.kts: standalone script under build root isn't highlighted as standaloneKT-41281
Multiple Script Definitions warning shown in git project having multiple Gradle projects
IDE. Hints
KT-32368
Rework Inline hints settings so that they look appropriate with the new UI in 2019.3KT-38027
Support Code Vision feature in Kotlin
IDE. Hints. Parameter Info
KT-24172
Parameter info marks signature as inapplicable when using argument labelsKT-41617
Parameter Info shows nothing inside already present type arguments of supertypeKT-41645
Add support for mixed named arguments to parameter info popup
IDE. Inspections and Intentions
New Features
KT-14578
Suggest "Convert lambda to reference" intention for generic extension functionKT-19321
Warn if method with nullable return type always returns non-nullKT-20718
Add a quick fix for "this class has no constructor" error on 'expect' annotation classesKT-21223
Add inspection for incomplete destructuringKT-22420
Intention to replace a = b with b.also { a = it }KT-39930
Add inspection for nullable Boolean inif
conditionKT-40016
Replace 'a.toLowerCase() == b.toLowerCase()' with 'a.equals(b, ignoreCase = true)' inspectionKT-40283
Inspection which replacesalso
/apply
with nestedforEach
toonEach
KT-40769
Add intention to replace isBlank/isNotBlank method negation
Fixes
KT-12222
Intention 'Convert to block body' should take nullability of overriden method into account when expression is of platform typeKT-14395
Lambda to Reference doesn't work for generic typesKT-15846
'Change lambda expression return type' quick fix does nothingKT-15944
IDEA doesn't suggest to replace deprecated get set operator functions when it used as operatorKT-17222
"Convert reference to lambda" creates red code for method with default argument valuesKT-18125
"Wrap with let {...}" intention not available in all casesKT-20438
Naming convention inspections: factory functions that are named like classes are flaggedKT-24138
Incorrect behavior in "convert reference to lambda" with new inference enabled, on function reference with default argumentsKT-29844
"Create class from usage" should mark constructor of created class as internal if its parameters have internal visibilityKT-30928
"Show hints for suspend calls" is too easy to enable and hard to disableKT-31749
"Surround with null check" produces incorrect check for 'in' expressionKT-32963
Don't suggestjava
directory of a JVM source set in multiplatform project as a target forCreate actual
quick fixKT-33211
Quickfix "add parameter" for method references should infer functional type instead of KFunctionKT-33258
"Merge 'if's" intention drops comment before nested ifKT-34572
Convert to block body action improperly works with suppress annotationsKT-35128
IntentionConvert member to extension
hides property delegate text with single line commentKT-35214
IntentionPut parameters on one line
: don't suggest if parameters has end-of-line commentsKT-35320
False positive "Replace explicit parameter 'x' with 'it'" in 'when' expression which returns lambdaKT-35525
False positive intention for 'run': "Convert to 'let'" when invoked without receiverKT-35526
Intention "Eliminate argument of 'when'" is broken for 'when' expression without 'else' branchKT-35805
FoldInitializerAndIfToElvis: should not add new line for multiline initializerKT-36051
IfThenToSafeAccessInspection: do not report if condition is SENSELESS_COMPARISONKT-37748
"Convert anonymous function to lambda expression" intention does not add necessary lambda type parameterKT-37841
IllegalStateException after "add non-null asserted call" on nullable function referenceKT-38139
False negative "Add suspend modifier" quickfix when suspend function is called in inline lambdaKT-38267
False positive "Call on collection type may be reduced" with Java platform types: suggested to reduce 'mapNotNull' call to 'map'KT-38282
False positive "Remove redundant spread operator" inspection with array as class property or fun argumentKT-39200
False positive "Redundant qualifier name" with same-named member object and companion propertyKT-39263
False positive "Variable should be inlined" for override value in initialized objectKT-39311
Batch quick fix name for "Change file's package" is truncatedKT-39393
"Convert anonymous function to lambda expression" intention does not add necessary lambda type parameter for outer functionKT-39454
False positive "Unused symbol" with private anonymous object propertyKT-39467
False negative "Move variable declaration into when" if a variable declaration is placed on a new lineKT-39490
'Wrap with ?.let' quickfix put the receiver inlet
lambdaKT-39552
Merge 'if's intention drops comment after nested ifKT-39604
"Package directive doesn't match file location" quick fix does not insert a space between keywordpackage
and the package nameKT-39772
"Redundant 'Unit'" should support lambdasKT-40215
"Create abstract function" quick fix suggested even though surrounding class is non-abstractKT-40448
"Convert call chain into sequence": support functions added in Kotlin 1.4KT-40558
False positive "Move to class body" intention on data class constructor propertyKT-41338
False positive "Redundant 'asSequence' call" when Map.Entry properties are used.KT-41615
"Unused equals expression" inspection: highlight whole expression with yellow background
IDE. JS
KT-39319
KJS: Support debugging through new Intellij 202 APIKT-41328
KJS / Gradle: explicitApi mode doesn't work
IDE. KDoc
KT-17926
IDE should show documentation for a class if the constructor has no docs.KT-19069
KDoc: show default argument valuesKT-37132
Redundant @NotNull annotation in a Quick Documentation pop-up
IDE. Misc
KT-39327
Get rid of usages of internal classes ModuleOrderEntryImpl and LibraryImplKT-40455
Improve support for EditorConfig
IDE. Navigation
KT-24616
Find usages fails to find setter usageKT-38762
"Cannot access 'java.io.Serializable' which is a supertype of 'kotlin.Int'" brokes navigation to constructor parameter declarationKT-39558
Call Hierarchy shows references from KDocKT-40788
"Find usages" on Java getter overridden in Kotlin doesn't find synthetic property usage when it is called without base declarationKT-40960
Unable to find usages in java of Kotlin constructor in library when sources is attached.
IDE. Project View
KT-37528
'Add Kotlin File/Class' suggests file before class
IDE. Refactorings
KT-19744
"Change Signature" is not available onconstructor
keyword in primary constructorKT-22170
"Change Signature" ignores Java usages of methods marked with @JvmStaticKT-37517
Invalid qualified name on copy-paste in build.gradle.kts
IDE. Run Configurations
KT-24463
MPP, Intellij runner: Run does not add resource directory to classpathKT-36370
Hide run gutter icons for not yet implemented targets in multiplatform projectsKT-39788
MPP, Gradle runner: Run does not add resource directory to classpath on project reopen without Gradle sync
IDE. Scratch
KT-40557
IDE / Scratch: .kt files are treated as Kotlin scratches, opening fails
IDE. Script
KT-35825
Custom kotlin scripts have no project import suggestions in sub modules.KT-39796
Performance of KotlinScriptDependenciesClassFinder
IDE. Tests Support
KT-28854
Run/Debug configurations: "Redirect input from" option is not available for Kotlin appsKT-36909
IDE attempts to run non-JVM tests launched from context menu as JVM ones
IDE. Wizards
KT-37965
New Project wizard 1.4+: adding JUnit5 test library add dependency to runnerKT-40527
Node.JS application template in New Project WizardKT-40874
Open new project wizard help page in browser when clicking help button in new project wizardKT-41417
Add react template to new project wizardKT-41418
Wizard: Support KJS compiler choiceKT-41958
New project wizard: Backend/Console applications template with Groovy DSL missing compileTestKotlin block
JavaScript
KT-39088
[ KJS / IR ] IllegalStateException: Concrete fake override IrBasedFunctionHandleKT-39367
KJS: .d.ts generation not working for objectsKT-39378
KJS / IR: "IllegalStateException: Operation is unsupported" with binaries.executable() and external function insidefor
loop with Iterator as return type
Middle-end. IR
KT-40193
IR: pluginContext.referenceClass() is not resolving typealiasKT-41181
Kotlin/Native 1.4.0 compiler fails on data class with >120 fields
Native. C and ObjC Import
KT-41639
Use LazyIR for enums and structs from cached librariesKT-41655
Native: "type cnames.structs.S of return value is not supported here: doesn't correspond to any C type" when accessing forward-declared-struct-typed C global variable
Native. ObjC Export
KT-38641
Kotlin-Multiplatform: Objective-Cdescription
method name collision in Swift
Tools. Android Extensions
KT-39981
Android parcel 'java.lang.VerifyError: Bad return type'
Tools. CLI
KT-35111
Extend CLI compilers help with link to online docs
Tools. Commonizer
KT-41220
[Commonizer] Short-circuit type aliasesKT-41247
[Commonizer] Missed supertypes in commonized classKT-41643
Commonizer exception for targets [ios_x64], [macos_x64]
Tools. Gradle
KT-33908
Make Kotlin Gradle plugin compatible with the Gradle configuration cacheKT-35341
KotlinCompile: Symlinked friend paths are no longer supported
Tools. Gradle. JS
New Features
KT-35330
Allow to customise generated package.jsonKT-39825
Provide single point of Webpack configuration in Gradle scriptKT-41054
Support Yarn resolutionsKT-41340
Add flag to suppress kotlin2js deprecation messageKT-41566
Kotlin/JS: Support JavaScript Library distribution
Fixes
KT-39515
package.json is regenerated without a visible reasonKT-39995
Collect statistic about generateExternals featureKT-40087
Kotlin/JS, IR backend: browserRun: update in continuous mode fails: "ENOENT: no such file or directory" referring output .jsKT-40159
Implement workaround / fix for webpack's "window is not defined"KT-40178
Browser run task prints output in TeamCity formatKT-40201
Kotlin/JS: Gradle: public package.json has emptydevDependencies {}
KT-40342
[Gradle, JS, Maven] "Cannot find module" generating fake NPM module from Maven dependendencyKT-40462
Collect statistic about usages of kotlin.js.generate.executable.default optionKT-40753
Type script definition file is not referenced as types in the package.jsonKT-40812
Node.JS run working directoryKT-40865
KJS / Gradle: Registering a task with a type that directly extends AbstractTask has been deprecatedKT-41125
Bump NPM versions in 1.4.20KT-41286
KJS / Gradle: args order in runTask is changed in 1.4.0KT-41475
KJS / Gradle: debug mode doesn't support custom launchers in karma configKT-41662
Kotlin/JS: with CSS support mode == "extract" browser test fails even without CSS usage: "Error in config file!"
Tools. Gradle. Native
KT-39764
Assertions are disabled when running K/N compiler in Gradle processKT-39999
Cocoapods plugin's dummy header cannot be compiledKT-41367
CocoaPods Gradle plugin: support git repository dependency
Tools. Incremental Compile
KT-37446
Incremental analysis for Java sources fails when run on JDK 11
Tools. J2K
KT-20421
J2K: SUPERTYPE_NOT_INITIALIZED for object extending base classKT-37298
J2K: implicit widening conversion for whole argument expression is transformed to cast on subexpressionKT-38879
J2K loses class annotations when converting class to objectKT-39149
J2K fails with augmented assignment operators when multiplying int by a non-intKT-40359
J2K: Conversion of invalid octal numbers throws NumberFormatExceptionKT-40363
J2K: Converting HEX integer literal in for-loop throws NumberFormatException
Tools. Scripts
KT-38404
Scripting API: Provide Location of Annotation Usage