Releases
v1.0.3
Compiler
Analysis & diagnostics
Combination of open
and override
is no longer a warning
KT-4829
Equal conditions in when
is now a warning
KT-6611
"This cast can never succeed" warning is no longer reported for Foo<T> as Foo<Any>
KT-7174
Declaring members with the same signature as non-overridable methods from Java classes (like Object.wait/notify) is now an error (when targeting JVM)
KT-12302
abstract
modifier for a member of interface is no longer a warning
KT-12452
open
modifier for a member of interface without implementation is now a warning
KT-11111
Overriding by inline function is now a warning, overriding by a function with reified type parameter is an error
KT-12337
Reference to a property with invisible setter now has KProperty type (as opposed to KMutableProperty)
Issues fixed
KT-4285
No warning for a non-tail call when the method inherits default arguments from superclass
KT-4764
Spurious "Variable must be initialized" in try/catch/finally
KT-6665
Unresolved reference leads to marking subsequent code unreachable
KT-9597
NullPointerException during resolution of complicated star projections
KT-11750
Exceptions when creating various entries with the name "name" in enums
KT-11998
Smart cast to not-null is not performed on a boolean property in if
condition
KT-10648
Exhaustiveness check does not work when sealed class hierarchy contains intermediate sealed classes
KT-10717
Type inference for lambda with local return
KT-11266
Fixed "Empty intersection of types" internal compiler error for some cases
KT-11857
Fix visibility check for dynamic members within protected method (when targeting JS)
KT-12589
Improved "infix
modifier is inapplicable" diagnostic message
KT-11679
Erroneous call with argument causes Throwable at ResolvedCallImpl.getArgumentMapping()
KT-12623
Fix ISE on malformed code
JVM code generation
KT-5075
Optimize array/collection indices usage in for
loop
KT-11116
Optimize coercion to Unit, POP operations are backward-propagated
Issues fixed
KT-11499
Compiler crashes with "Incompatible stack heights"
KT-11943
CompilationException with extension property of KClass
KT-12125
Wrong increment/decrement on Byte/Char/Short.MAX_VALUE/MIN_VALUE
KT-12192
Exhaustiveness check isn't generated for when expression returning Unit
KT-12200
Erroneously optimized away assignment to a property initialized to zero
KT-12582
"VerifyError: Bad local variable type" caused by explicit loop variable type
KT-12708
Bridge method not generated when data class implements interface with copy() method
KT-12106
import static of reified companion object method throws IllegalAccessError
Performance
Reduced number of IO operation when loading kotlin compiled classes
Сompiler options
Allow to specify version of Kotlin language for source compatibility with older releases.
CLI: -language-version
command line option
Maven: languageVersion
configuration parameter, linked with kotlin.compiler.languageVersion
property
Gradle: kotlinOptions.languageVersion
property in task configuration
Allow to specify which java runtime target version to generate bytecode for.
CLI: -jvm-target
command line option
Maven: jvmTarget
configuration parameter, linked with kotlin.compiler.jvmTarget
property
Gradle: kotlinOptions.jvmTarget
property in task configuration
Allow to specify path to JDK to resolve classes from.
CLI: -jdk-home
command line option
Maven: jdkHome
configuration parameter, linked with kotlin.compiler.jdkHome
property
Gradle: kotlinOptions.jdkHome
property in task configuration
Standard Library
Improve documentation (including KT-11632
)
List iteration used in collection operations is performed with an indexed loop when the list supports RandomAccess
and the operation isn't inlined
IDE
Completion
New features
Smart completion after by
and in
Improved completion in bodies of overridden members (when no type is specified)
Improved presentation of completion items for property accessors
Fixed keyword completion after try
in assignment expression
KT-8527
Include non-imported declarations on the first completion
KT-12068
Special completion item for "[]" get-operator access
KT-12080
Parameter names are now higher up in completion list
Issues fixed
Fixed enum members being present in completion as static members
Fixed QuickDoc not working for properties generated for java classes
KT-9166
Code completion does not work for synthetic java properties on typing "g"
KT-11609
No named arguments completion should be after dot
KT-11633
Wrong indentation after completing a statement in data class
KT-11680
Code completion of label for existing return with value inserts redundant whitespace
KT-11784
Completion for if
statement should add parentheses automatically
KT-11890
Completion for callable references does not propose static Java members
KT-11912
String interpolation is not converted to ${} form when accessing this.property
KT-11957
No catch
and finally
keywords in completion
KT-12103
Smart completion for nested SAM-adapter produces short unresolved name
KT-12138
Do not show "::error" in smart completion when any function type accepting one argument is expected
KT-12150
Smart completion suggests to compare non-nullable with null
KT-12124
No code completion for a java property in a specific position
KT-12299
Completion: incorrect priority of property foo over method getFoo in Kotlin-only code
KT-12328
Qualified function name inserted when typing before if
KT-12427
Completion doesn't work for "@receiver :" annotation target
KT-12447
Don't use CompletionProgressIndicator in Kotlin plugin
KT-12669
Completion should show variant with ()
when there is default lambda
KT-12369
Pressing dot after class name should not cause insertion of constructor call
Spring support
New features
Issues fixed
KT-12091
Fixed unstable behavior of Spring line markers
KT-12096
Fixed rename of custom-named beans specified with Kotlin annotation
KT-12117
Group Kotlin classes from the same file in the Choose Bean dialog
KT-12120
Show autowiring candidates line markers for @Autowired-annotated constructors and constructor parameters
KT-12122
Fixed line marker popup on functions with @Qualifier-annotated parameters
KT-12143
Fixed "Spring Facet Code Configuration (Kotlin)" inspection description
KT-12147
Fixed exception on analyzing object declaration with @component annotation
KT-12148
Warn about object declarations annotated with Spring @Configuration
/@Component
/etc.
KT-12363
Fixed "Autowired members defined in invalid Spring bean (Kotlin)" inspection description
KT-12366
Fixed exception on analyzing class declaration upon annotation typing
KT-12384
Fixed bean references in factory method calls
Intention actions, inspections and quickfixes
New features
New icon for "New -> Kotlin Activity" action
"Change visibility on exposure" and "Make visible" fixes now support all possible visibilities
KT-8477
New inspection "Can be primary constructor property" with quick-fix
KT-5010
"Redundant semicolon" inspection with quickfix
KT-9757
Quickfix for "Unused lambda expression" warning
KT-10844
Quick fix to add crossinline modifier
KT-11090
"Add variance modifiers to type parameters" inspection
KT-11255
Move Element Left/Right actions
KT-11450
"Modality is redundant" inspection
KT-11523
"Add @jvmoverloads annotation" intention
KT-11768
"Introduce local variable" intention
KT-11806
Quick-fix to increase visibility for invisible member
KT-11807
Use function body template when generating overriding functions with default body
KT-11864
Suggest "Create function/secondary constructor" quick fix on argument type mismatch
KT-11876
Quickfix for "Extension function type is not allowed as supertype" error
KT-11920
"Increase visibility" and "Decrease visibility" quickfixes for exposed visibility errors
KT-12089
Quickfix "Make primary constructor parameter a property"
KT-12121
"Add toString()
call" quickfix
KT-11104
New quickfixes for nullability problems: "Surround with null check" and "Wrap with safe let call"
KT-12310
New inspection "Member has platform type" with quickfix
Issues fixed
Fixed "Convert property initializer getter" intention being available inside lambda initializer
Improved message for "Can be declared as val
" inspection
KT-3797
Quickfix to make a function abstract should not be offered for object members
KT-11866
Suggest "Create secondary constructor" when constructors exist but are not applicable
KT-11482
Fixed exception in "Move to companion object" intention
KT-11483
Pass implicit receiver as argument when moving member function to companion object
KT-11512
Allow choosing any source root in "Move file to directory" intention
KT-10950
Keep original file package name when moving top-level declarations to separate file (provided it's not ambiguous)
KT-10174
Optimize imports after applying "Move declaration to separate file" intention
KT-11764
Intention "Replace with a forEach
function call should replace continue
with return@forEach
KT-11724
False suggestion to replace with compound assignment
KT-11805
Invert if-condition intention breaks code in case of end of line comment
KT-11811
"Make protected" intention for a val declared in parameters of constructor
KT-11710
"Replace if
with elvis operator": incorrect code generated for if
expression
KT-11849
Replace explicit parameter with it
changes the meaning of code because of the shadowing
KT-11870
"Replace with Elvis" refactoring doesn't change the variable type from T? to T
KT-12069
Specify language for all Kotlin code inspections
KT-11366
"object Companion
is never used" warning in intellij
KT-11275
Inconsistent behaviour of "move lambda argument out of parentheses" intention action when using lambda calls with function arguments without parentheses
KT-11594
"Add non-null asserted (!!) call" applied to unsafe cast to nullable type causes AE at KtPsiFactory.createExpression()
KT-11982
False "Redundant final modifier" reported
KT-12040
"Replace when with if" produce invalid code for first entry which has comment
KT-12204
"Use classpath of module" option in existing Kotlin run configuration may be changed when a new run configuration is created
KT-10635
Don't mark private writeObject and readObject methods of Serializable classes as unused
KT-11466
"Make abstract" quick fix applies to outer class of object with accidentally abstract function
KT-11120
Constructor parameter/field reported as unused symbol even if it have used
annotation
KT-11974
Invert if-condition intention loses comments
KT-10812
Globally unused constructors are not marked as such
KT-11320
Don't mark @BeforeClass (JUnit4) annotated functions as unused
KT-12267
"Change type" quick fix converts to Int for Long literal
KT-11949
Various problems fixed with "Constructor parameter is never used as a property" inspection
KT-11716
"Simply for
using destructuring declaration" intention: incorrect behavior for data classes
KT-12145
"Simplify for
using destructuring declaration" should work even when no variables declared inside loop
KT-11933
Entities used only by alias are marked as unused
KT-12193
Convert to block body isn't equivalent for when expressions returning Unit
KT-10779
Simplify for
using destructing declaration: intention / inspection quick fix is available only when all variables are used
KT-11281
Fix exception on applying "Convert to class" intention to Java interface with Kotlin inheritor(s)
KT-12285
Fix exception on test class generation
KT-12502
Convert to expression body should be forbidden for non-exhaustive when returning Unit
KT-12260
ISE while replacing an operator with safe call
KT-12649
"Convert if to when" intention incorrectly deletes code
KT-12671
"Shot type" action: "Type is unknown" error on an invoked expression
KT-12284
Too wide applicability range for "Add braces to else" intention
KT-11975
"Invert if-condition" intention does not simplify is
expression
KT-12437
"Replace explicit parameter" intention is suggested for parameter of inner lambda in presence of it
from outer lambda
KT-12290
Navigate to the generated declaration when using "Implement abstract member" intention
KT-12376
Don't show "Package directive doesn't match file location" in injected code
KT-12777
Fix exception in "Create class" quickfix applied to unresolved references in type arguments
Language injection
Apply injection for the literals in property initializer through property usages
Enable injection from Java or Kotlin function declaration by annotating parameter with @language annotation
KT-2428
Support basic use-cases of language injection for expressions marked with @language annotation
KT-11574
Support predefined Java positions for language injection
KT-11472
Add comment or @language annotation after "Inject language or reference" intention automatically
Refactorings
New features
KT-6372
Add name suggestions to Rename dialog
KT-7851
Respect naming conventions in automatic variable rename
KT-8044
, KT-9432
Support @JvmName annotation in rename refactoring
KT-8512
Support "Rename tests" options in Rename dialog
KT-9168
Support rename of synthetic properties
KT-10578
Support automatic test renaming for facade files
KT-12657
Rename implicit usages of annotation method value
KT-12759
Suggest renaming both property accessors with matching @JvmName when renaming one of them from Java
Issues fixed
KT-4791
Rename overridden property and all its accessors on attempt to rename overriding accessor in Java code
KT-6363
Do not rename ambiguous references in import directives
KT-6663
Fixed rename of ambiguous import reference to class/function when some referenced declarations are not changed
KT-8510
Preserve "Search in comments and strings" and "Search for text occurrences" settings in Rename dialog
KT-8541
, KT-8786
Do now show 'Rename overloads' options if target function has no overloads
KT-8544
Show more detailed description in Rename dialog
KT-8562
Show conflicts dialog on attempt of redeclaration
KT-8611
Qualify class references to resolve rename conflicts when possible
KT-8732
Implement Rename conflict analysis and fixes for properties/parameters
KT-8860
Allow renaming class by constructor delegation call referencing primary constructor
KT-8892
Suggest renaming base declarations on overriding members in object literals
KT-9156
Quote non-identifier names in Kotlin references
KT-9157
Fixed in-place rename of Kotlin expression referring Java declaration
KT-9241
Do not replace Java references to synthetic component functions when renaming constructor parameter
KT-9435
Process property accessor usages (Java) in comments and string literals
KT-9444
Rename dialog: Allow typing any identifier without backquotes
KT-9446
Copy default parameter values to overriding function which is renamed while its base function is not
KT-9649
Constraint search scope of parameter declared in a private member
KT-10033
Qualify references to members of enum companions in case of conflict with enum entries
KT-10713
Skip read-only declarations when renaming parameters
KT-10687
Qualify property references to avoid shadowing by parameters
KT-11903
Update references to facade class when renaming file via matching top-level class
KT-12411
Fix package name quotation in Move refactoring
KT-12543
Qualify property references with this
to avoid renaming conflicts
KT-12732
Copy default parameter values to overriding function which is renamed by Java reference while its base function is unchanged
KT-12747
Fix exception on file copy
Java to Kotlin converter
New features
KT-4727
Convert Java code copied from browser or other sources
Issues fixed
KT-11952
Assertion failed in PropertyDetectionCache.get on conversion of access to Java constant of anonymous type
KT-12046
Recursive property setter
KT-12039
Static imports converted missing ".Companion"
KT-12054
Wrong conversion of instanceof
checks with raw types
KT-12045
Convert Object()
to Any()
Android Lint
Issues fixed
KT-12015
False positive for Bundle.getInt()
KT-12023
"minSdk" lint check doesn't work for as
/is
KT-12674
"Calling new methods on older versions" errors for inlined constants
KT-12681
Running lint from main menu: diagnostics reported for java source files only
KT-12173
False positive for "Toast created but not shown" inside SAM adapter
KT-12895
NoSuchMethodError thrown when saving a Kotlin file
KDoc
New features
Issues fixed
Rendering of _
and *
standalone characters
Rendering of code blocks
KT-9933
Indentation in code fragments is not preserved
KT-10998
Spaces around links are missing in return block
KT-11791
Markdown links rendering
KT-12001
Allow use of @param
to document type parameter
Maven support
New features
Inspections that check that kotlin IDEA plugin, kotlin Maven plugin and kotlin stdlib are of the same version
KT-11643
Inspections and intentions to fix erroneously configured Maven pom file
KT-11701
"Add Maven Dependency quick fix" in Kotlin source files
KT-11743
Intention to replace kotlin-test with kotlin-test-junit
Issues fixed
KT-9492
Configuring multiple Maven Modules
KT-11642
Kotlin Maven configurator tags order
KT-11436
"Choose Configurator" control opens dialogs with inconsistent modality (linux)
KT-11731
Default maven integration doesn't include documentation
KT-12568
Execution configuration: file path completion works only in some sub-elements of
KT-12558
Configure Kotlin in Project: "Undo" should revert changes in all poms
KT-12512
"Different IDE and Maven plugin version" inspection is being invoked for non-tracked pom.xml files
Debugger
New features
KT-11438
Support navigation from stacktrace to inline function call site
Issues fixed
Do not step into inline lambda argument during step over inside inline function body
Fix step over for inline argument with non-local return
KT-12067
Deadlock in Kotlin debugger is fixed
KT-12232
No code completion in Evaluate Expression and Throwable at CodeCompletionHandlerBase.invokeCompletion()
KT-12137
Evaluate expression: code completion/intention actions allows to use symbols from modules that are not referenced
KT-12206
NoSuchFieldError in Evaluate Expression on a property of a derived class
KT-12678
NoSuchFieldError in Evaluate Expression on accessing delegated property defined in other module
KT-12773
Fix debugging for Kotlin JS projects
Formatter
Issues fixed
KT-12035
Spaces around as
KT-12018
Spaces between function name and arguments in infix calls
KT-11961
Spaces before angle bracket in method definition
KT-12175
Don't enforce empty line between secondary constructors without body
KT-12548
Spaces around is
keyword
KT-12446
Spaces before class type parameters
KT-12634
Spaces between method name and parenthesis in method call
KT-10680
Spaces around in
keyword
KT-12791
Spaces between curly brace and expression inside string template
KT-12781
Spaces between annotation and expression
KT-12689
Spaces around semicolons
KT-12714
Spaces around parentheses in enum elements
Other
New features
Added "Decompile" button to Kotlin bytecode toolwindow
Added Kotlin "Tips of the day"
Added "Kotlin 1.1 EAP" to "Configure Kotlin Plugin updates"
KT-2919
Constructor calls are no longer highlighted as classes
KT-6540
Infix function calls are now highlighted as regular function calls
KT-9410
Annotations in Kotlin are now highlighted with the same color as in Java by default
KT-11465
Type parameters in Kotlin are now highlighted with the same color as in Java by default
KT-11657
Allow viewing decompiled Java source code for Kotlin-compiled classes
KT-11704
Support file path references inside of Kotlin string literals
KT-12076
Kotlin Plugin update check: always display installed version number
KT-11814
New icon for kotlin annotation classes
KT-12735
Convert JavaDoc to KDoc when overriding Java class member in Kotlin
Issues fixed
KT-5960
Can't find usages for Java methods used from Kotlin by call convention
KT-8362
"New Kotlin file": Keywords should be escaped in package name
KT-8682
Respect "Copy JavaDoc" option in the "Override/Implement Members..." dialog
KT-8817
Fixed rename of Java getters/setters through synthetic property references in Kotlin
KT-9399
Find Usages omits Kotlin annotation parameter usage in Java source
KT-9797
"Kotlin Bytecode" toolwindow breaks after closing
KT-11145
Use progress indicator when searching usages in Introduce Parameter
KT-11155
Allow running multiple Kotlin classes as well as running mixtures of Kotlin and Java classes
KT-11495
Show recursion line markers for extension function calls with different receiver
KT-11659
Generate abstract overrides for Any members inside of Kotlin interfaces
KT-12070
Add empty line in error message of Maven and Gradle configuration
KT-11908
Allow properties with custom setters to be used in generated equals/hashCode/toString
KT-11617
Fixed title of Introduce Parameter declaration chooser
KT-11817
Fixed rename of Kotlin enum constants through Java references
KT-11816
Fixed usages search for Safe Delete on simple enum entries
KT-11282
Delete interface reference from super-type list when applying Safe Delete to Java interface
KT-11967
Fix Find Usages/Rename for parameter references in XML files
KT-10770
"Optimize imports" will not keep import if a type is only referenced by kdoc
KT-11955
Copy/Paste inserts fully qualified name when copying function with overloads
KT-12436
"Replace explicit parameter with it": java.lang.Exception at BaseRefactoringProcessor.run()
KT-12440
Removing unused parameter results in Exception "Refactorings should not be started inside write action"
KT-12006
getLanguageLevel is slow for Kotlin light classes
KT-12026
"Constant expression required" in Java for const Kotlin values
KT-12259
ClassCastException in light classes while trying to create generic property
KT-12289
Remove unnecessary ?
from serr
live template
KT-12110
Map help button of the Compiler - Kotlin page
KT-12075
Kotlin Plugin update check: make dumbaware
KT-10255
call BuildManager.clearState(project) in apply() method of Kotlin Compiler Settings configurable
KT-11841
New Project / Module wizard, Gradle: pure Kotlin module is created without repositories
call in build.gradle
KT-11095
Java cannot infer generic return type of Kotlin function (with java 8 language level)
KT-12090
Intellij/Kotlin plugin does not handle generic return type of static method defined in Kotlin, called from Java
KT-12206
Fix NoSuchFieldError on accessing base property without backing field in evaluate expression
KT-12516
File Structure: Kotlin annotation classes have Java annotation icons
KT-11328
"New Kotlin class": generates packages when fully qualified name is specified
KT-11778
Exception in Lombok plugin: Rewrite at slice FUNCTION
KT-11708
"Go to declaration" doesn't work on a call to function with SAM conversion on a derived type
KT-12381
Prefer not-nullable return type when overriding Java method without nullability annotation
KT-12647
Performance improvement for test-related line markers
KT-12526
Kotlin intentions increase PSI modification counts from isAvailable, even in daemon threads
Reflection
Issues fixed
KT-11531
Optimize "KCallable.name"
KT-10771
Reflection on Function objects does not support lambdas with generic return type
KT-11824
Reflection inconsistency between member property and accessor
JS
Improve performance of maps and sets
Issues fixed
KT-6942
Generate structural equality check (i.e. Any.equals
) instead of referential check (===) value equality patterns in when
KT-7228
Wrong AbstractList signature
KT-8299
Wrong access to private member in autogenerated code in data class
KT-11346
Reified functions like filterIsInstance
are now available in JS Standard Library
KT-12305
Incorrect translation of vararg
in @native
functions
KT-12254
JsEmptyExpression in initializer when compiling code like val x = throw Exception()
KT-11960
Wrong code generated when a method of a local class calls constructor of the class
KT-10931
Incorrect inlining of library method with optional parameters
KT-12417
Wrong check cast generated for KMutableProperty
Tools
New features
KT-11839
Maven goal to execute kotlin script
Issues fixed
KAPT: fix error when using enum constructors with parameters
Various problems with gradle 2.2 fixed: KT-12478
, KT-12406
, KT-12478
KT-12595
JPS: Fixed com.intellij.util.io.MappingFailedException: Cannot map buffer
KT-11166
Gradle: Unable to access internal classes from test code within the same module
KT-12352
KAPT: Fix "Classpath entry points to a non-existent location" warnings
KT-12074
Building Kotlin maven projects using a parent pom will silently fail
KT-11770
Warning "RuntimeException: Could not find installation home path" when using Gradle Incremental Compilation
KT-10969
Android extensions: NullPointerException when finding view in Fragment
KT-11885
Gradle/Android: Unresolved reference "kotlinx" when classpath dependency is defined in root build.gradle
KT-12786
Deprecation warning with Gradle 2.14
You can’t perform that action at this time.