Mikhail Glukhikh
fdc0335b4a
Add actual: handle (incorrect) case with expect function with body
...
So #KT-23326 Fixed
2018-06-29 10:54:37 +03:00
Mikhail Glukhikh
0fb183e302
Add actual: handle parameters with val/var as compatible with property
...
So #KT-23762 Fixed
2018-06-29 10:54:36 +03:00
Mikhail Glukhikh
dd0b267531
Add actual: handle primary & secondary constructors as compatible
...
So #KT-23686 Fixed
2018-06-29 10:54:35 +03:00
Mikhail Glukhikh
16c6d63b10
Create actual: do not generate default parameter values
...
So #KT-23105 Fixed
2018-06-29 10:54:32 +03:00
Mikhail Glukhikh
aac71bf904
Safe delete: when invoking on actual, delete expect & actual neighbors
...
So #KT-15666 Fixed
2018-06-29 10:54:24 +03:00
Mikhail Glukhikh
50e70e4638
Safe delete: when invoking on expect, delete also relevant actual
...
Partial fix of KT-15666
2018-06-29 10:53:43 +03:00
Mikhail Glukhikh
465d5c077e
Safe delete: search for actual declarations more accurately
2018-06-29 10:53:42 +03:00
Alexey Sedunov
60583e557f
PSI: Do not delete package directive for file in default package
...
#KT-24968 Fixed
2018-06-28 18:22:28 +03:00
Alexey Sedunov
bede2e1c16
Extract Interface: Fix type import when converting parameter to property
...
#KT-18736 Fixed
2018-06-28 17:52:05 +03:00
Alexey Sedunov
9b7450cfdb
Extract Superclass: Report private members used in abstracted members
...
#KT-16284 Fixed
2018-06-28 17:52:04 +03:00
Alexey Sedunov
bd88e02172
Extract Superclass: Fix visibility lifting when moving to interface
...
#KT-16281 Fixed
2018-06-28 17:52:04 +03:00
Alexey Sedunov
b0e0460ee6
Extract Superclass: Allow extraction to existing file
...
#KT-15351 Fixed
2018-06-28 17:52:04 +03:00
Mikhail Zarechenskiy
dc7678a700
Use smartcast info that related to call in change signature quick fix
...
There is an inconsistency on how we record smartcasts in old and new
inference, but we definitely should use all possible information about
smartcasts in quick-fixes
#KT-25144 Fixed
2018-06-28 13:14:18 +03:00
Mikhail Glukhikh
eb92b7ed7f
Unused symbol: don't suggest actual declaration used in another platform
...
Related to KT-17512
Related to KT-15666
2018-06-26 15:36:10 +03:00
Mikhail Glukhikh
30327aa9cc
Do not mark kotlin.test.Test annotated declarations as unused
...
So #KT-20523 Fixed
2018-06-26 15:36:09 +03:00
Mikhail Glukhikh
7e0e7dc983
Unused symbol: remove forced "used" from actual declarations
...
Now we really check whether actual declaration has usages
(in expect or actual code) or not
Related to KT-17512
Related to KT-15666
2018-06-26 15:36:07 +03:00
Mikhail Glukhikh
e885e54233
Implement search from expect element in KotlinReferenceSearcher
...
So mostly #KT-17512 Fixed
2018-06-26 15:36:06 +03:00
Mikhail Glukhikh
cc2869988f
Test for KT-17512 (yet with incorrect results)
2018-06-26 15:35:58 +03:00
Nikolay Krasko
8e31113a4f
Ident elvis with normal ident in Kotlin code style (KT-25008)
...
#KT-25008 Fixed
2018-06-22 19:19:13 +03:00
Nikolay Krasko
1973860e70
Indent content of when (KT-14066)
...
#KT-14066 Fixed
2018-06-22 19:19:12 +03:00
Toshiaki Kameyama
5a4cba7528
"To raw/ordinary string literal" intention: Move cursor to same offset after conversion #KT-18106 Fixed ( #1675 )
2018-06-21 15:56:18 +03:00
Mikhail Glukhikh
152327d69d
Fix erroneous full resolve cache filling
...
Before this commit, we could store partial resolve results in full
resolve cache (for some declarations, e.g. primary constructors).
This may be done iff current partial resolve mode provides all results
from full resolve mode (CFA results & diagnostics).
Otherwise we should not do it.
This fixes four quick-fix tests on CreateTypeParameter
So #KT-23860 Fixed
So #KT-22758 Fixed
2018-06-20 17:18:18 +03:00
Toshiaki Kameyama
096f9fefd1
"Remove redundant '.let' call" intention: handle it inside function call
...
So #KT-20583 Fixed
2018-06-20 17:18:17 +03:00
kenji tomita
817d75a47f
Introduce ReplaceToStringWithStringTemplateInspection #KT-13782 Fixed
2018-06-20 17:18:17 +03:00
Dmitry Petrov
f956e8d85d
Record special descriptor in REFERENCE_TARGET for type alias object
...
If a type alias is used to reference an object (companion object) as a
qualifier, record FakeCallableDescriptorForTypeAliasObject in
REFERENCE_TARGET. This tells IDE that type alias was used in the file,
thus, if it's imported, such import isn't redundant.
REFERENCE_TARGET is used mostly by IDE and by ClassifierUsageChecker,
which we also have to update to handle qualifiers with
FakeCallableDescriptorForTypeAliasObject in REFERENCE_TARGET.
Rewrite some parts of ClassifierUsageChecker for cleaner interaction.
#KT-21863 Fixed Target versions 1.2.40
2018-06-20 17:16:25 +03:00
Toshiaki Kameyama
6675d7814c
KT-14779 Inspection to replace String.format with string templates ( #1645 )
...
* Add inspection to replace String.format with string templates #KT-14779 Fixed
* KT-14779 Fixed
2018-06-20 16:23:04 +03:00
Toshiaki Kameyama
e41a34af88
KT-11850 Add nested lambdas with implicit parameters warning ( #1664 )
...
* Add `Nested lambda has shadowed implicit parameter` inspection #KT-11850 Fixed
* KT-11850 Fixed
2018-06-20 15:57:03 +03:00
Toshiaki Kameyama
1e31d24e9b
Add "Remove 'const'" quickfix for TYPE_CANT_BE_USED_FOR_CONST_VAL
...
So #KT-24815 Fixed
2018-06-19 12:48:13 +03:00
Toshiaki Kameyama
c344354395
Add quick-fix for 'is' absence in when #KT-18810 Fixed
2018-06-19 12:48:13 +03:00
Toshiaki Kameyama
2427406a8f
Add 'Change to val' quickfix for delegates without setValue
...
So #KT-13688 Fixed
2018-06-19 12:48:13 +03:00
Toshiaki Kameyama
3292137acb
"Convert lambda to anonymous function": Don't suggest in inline function
...
So #KT-24792 Fixed
2018-06-19 12:48:12 +03:00
Toshiaki Kameyama
fa58da85ee
Add indices: don't suggest if parameter is destructuring declaration
...
So #KT-22162 Fixed
2018-06-19 12:48:12 +03:00
Toshiaki Kameyama
2669193755
Use "Move to companion" quick fix for CONST_VAL_NOT_TOP_LEVEL_OR_OBJECT
...
So #KT-22871 Fixed
2018-06-19 12:48:12 +03:00
Toshiaki Kameyama
69d2e8898a
"Main should return Unit" inspection: extend on JUnit test methods
...
So #KT-24509 Fixed
2018-06-19 12:48:11 +03:00
Toshiaki Kameyama
b5e3db1811
Lambda to reference: fix false positive for parameter' class reference
...
So #KT-22041 Fixed
2018-06-19 12:48:11 +03:00
Toshiaki Kameyama
5ad98a139d
"Redundant Companion": Don't suggest if same callable name is in use
...
So #KT-24425 Fixed
2018-06-19 12:48:10 +03:00
Alexey Sedunov
16dbc6fb4d
Extract Function: Forbid inappropriate declarations inside extractable fragment
...
#KT-20467 Fixed
#KT-20469 Fixed
2018-06-19 12:22:40 +03:00
Alexey Sedunov
f7cda61b08
Copy/Paste: Add imports for non-qualifiable callable references
...
#KT-23407 Fixed
2018-06-19 12:22:40 +03:00
Alexey Sedunov
694997651a
Override/Implement: Fix processing of unresolved types
...
#KT-17350 Fixed
2018-06-19 12:22:40 +03:00
Alexey Sedunov
ed8b4b761a
Override/Implement: Add 'actual' modifier to overrides of 'expect'
...
#KT-23106 Fixed
2018-06-19 12:22:40 +03:00
Alexey Sedunov
5f87e84966
Override/Implement: Do not insert super-call into extension body
...
Such super-calls are not are supported yet
#KT-4311 Fixed
2018-06-19 12:22:39 +03:00
Alexey Sedunov
c49eede054
Generate hashCode()/equals(): Support deep array equality
...
#KT-19102 Fixed
2018-06-19 12:22:39 +03:00
Mikhail Glukhikh
9ef89447b3
Sealed sub-class -> object: handle equals, suggest "add equals"
...
Before this commit, sealed sub-class without state was considered
a style issue.
After this commit, sealed sub-class without state AND custom equals
is considered a probable bug,
because comparison of its instances is very fragile.
Alternative fix (generate equals & hashCode by identity) is added.
2018-06-19 11:20:26 +03:00
Mikhail Glukhikh
cbec005055
Add test for KT-21710 (gutters inside library sources)
2018-06-19 10:42:36 +03:00
Mikhail Glukhikh
cbcd35e2f5
Implement Kotlin sub-classes tooltip to handle MPP correctly
...
Before this commit, Java tooltip was in use which could not
work correctly with expect / actual classes
So #KT-21011 Fixed
2018-06-14 15:42:37 +03:00
Mikhail Glukhikh
232d340118
Expect/actual companion object: set gutter on leaf element
...
May fix KT-21113
2018-06-13 19:23:40 +03:00
Mikhail Glukhikh
cfd1a54463
Do not create expect / actual gutters for primary constructor
...
So #KT-22177 Fixed
So #KT-21063 Obsolete
2018-06-13 19:19:26 +03:00
Mikhail Glukhikh
b235af0656
Can be private: correct detection of calls inside inline accessors
2018-06-13 19:17:50 +03:00
Mikhail Glukhikh
faa8d92560
Unused receiver: do not report on actual declarations #KT-24562 Fixed
2018-06-13 18:12:36 +03:00
Mikhail Glukhikh
38632c2937
Can be private: correct detection of calls inside inline function
...
So #KT-22180 Fixed
So #KT-22094 Fixed
2018-06-13 18:12:34 +03:00