Dmitry Jemerov
4dd3f30f2d
Build stubs for local functions; show them in Goto Symbol
...
#KT-14161 Fixed
2017-05-18 21:02:24 +02:00
Dmitry Jemerov
8f38d03b48
Indicate vararg parameters in Goto Symbol presentation
...
#KT-17899 Fixed
2017-05-18 21:02:24 +02:00
Nikolay Krasko
c1538aea43
Get annotation for injection from reference descriptor (KT-15548)
...
#KT-15548 Fixed
2017-01-12 14:21:47 +03:00
Dmitry Petrov
a15d423db4
Support modifiers on types in parser
...
(required for 'suspend' on functional types).
TYPE_REFERENCE element now has MODIFIER_LIST child, which hosts annotations and modifiers for the corresponding type reference.
Annotations and modifiers written before an extension function type are now parsed as annotations and modifiers for the functional type, not the receiver type.
So, '@Ann A.(B) -> C' was '(@Ann A).(B) -> C', and became '@Ann (A.(B) -> C)'.
NB: DSL_SCOPE_VIOLATION testData updated accordingly.
Type projection variance modifiers ('in', 'out') belong to a separate modifier list under corresponding type projection (not under a type reference).
'A<in suspend T>' is 'A<(in (suspend T))>', 'A<suspend in T>' is an error.
In stub builder, create a modifier list node to host annotations and modifiers (none so far; TODO properly serialize/deserialize types with modifiers).
2016-12-15 23:57:41 +03:00
Nikolay Krasko
d1dfcfaca1
Fix stub-psi mismatch exception on restoring annotation for nullable types
...
(cherry picked from commit 1aa37f11258dde289a9f7cb700294a038168fbdc)
Conflicts:
compiler/frontend/src/org/jetbrains/kotlin/psi/stubs/KotlinStubVersions.kt
idea/idea-analysis/src/org/jetbrains/kotlin/idea/decompiler/stubBuilder/TypeClsStubBuilder.kt
2016-10-25 13:22:53 +03:00
Nikolay Krasko
355dca2a97
Add toString for KotlinStubBaseImpl
...
Try to simplify "Stub and PSI element type mismatch" exception analyze.
(cherry picked from commit 11aa71e)
2016-10-21 00:18:27 +03:00
Denis Zharkov
b5bdb070a0
Fix test data after 4725dd3
2016-07-16 09:10:35 +03:00
Alexander Udalov
7eafae1936
Drop isAbsoluteInRootPackage from stubs
2016-06-01 19:30:04 +03:00
Dmitry Jemerov
009e3f9cd7
rename PSI classes according to current terminology:
...
KtMultiDeclaration(Entry) -> KtDestructuringDeclaration(Entry)
KtFunctionLiteralExpression -> KtLambdaExpression
KtFunctionLiteralArgument -> KtLambdaArgument
KtDelegationSpecifierList -> KtSuperTypeList
KtDelegationSpecifier -> KtSuperTypeListEntry
KtDelegatorToSuperClass -> KtSuperTypeEntry
KtDelegatorToSuperCall -> KtSuperTypeCallEntry
KtDelegationByExpressionSpecifier ->KtDelegatedSuperTypeEntry
2015-12-10 16:15:13 +01:00
Pavel V. Talanov
dbd49c37c1
Psi: Introduce KtScriptInitializer, a separate entity for script initializers which are quite a bit different from class initializers
2015-11-19 22:57:07 +03:00
Pavel V. Talanov
aeb4abe39d
Fix decompiled text for named companion object
...
Fix stub/ast mismatch for compiled named companion objects
Add tests
2015-10-19 15:27:49 +03:00
Valentin Kipyatkov
090ea37a32
Fixed test data to use only annotation syntax with @
2015-10-15 19:20:08 +03:00
Denis Zharkov
e1e3a6c9ad
Introduce const into decompiler and stub builder
2015-09-23 08:20:57 +03:00
Denis Zharkov
fc447e2d2f
Parse some builtin annotations as modifiers
...
But still resolve them as annotations.
Mostly it's needed as begin of migration path, one day they become modifiers anyway
Some tests are dropped because they supposed that `annotation` should have parameter
2015-09-08 08:53:35 +03:00
Denis Zharkov
31244edec9
Deprecate deprecated in favor of Deprecated
2015-09-04 18:19:31 +03:00
Mikhail Glukhikh
022e7d1169
Deprecated enum syntax removed: most idea tests
2015-08-10 16:24:16 +03:00
Mikhail Glukhikh
1eac4d67de
"annotation" is now parsed as an identifier. It is no longer a soft keyword.
...
Sometimes it's allowed to parse "annotation" unescaped even if other annotations must be escaped.
A set of annotations and their options tests.
A swarm of existing tests fixed (mostly kotlin.annotation.annotation() added to txt-files).
STUB_VERSION increased. Some quick fixes slightly changed.
2015-07-14 16:24:55 +03:00
Denis Zharkov
c9f79c2d05
Adjust testData: get rid of obsolete annotations
2015-06-12 09:23:31 +03:00
Pavel V. Talanov
07d35d305e
Create import list psi element even if no directives are present
...
Fix a problem where deleting last import directive via "optimize imports" could lead to incorrect psi structure resulting in CCE, see EA-64291
New imports are inserted at the head (after package directive if present) of the file (before any comments) if no imports were present
Add test for inserting import to file where a first statement is a comment
Drop code dealing with non-existing import list in ImportInsertHelperImpl
AbstractQuickFixTest: check for unexpected actions before changes to the file are made as it relies on the first line having specific format
2015-06-08 20:51:04 +03:00
Valentin Kipyatkov
8fd6a64be9
Refactored methods for val/var in PSI
2015-06-01 18:23:34 +03:00
Dmitry Jemerov
625096466e
IDE testdata: s/trait/interface
2015-05-13 16:13:13 +02:00
Dmitry Jemerov
46841ef447
fix expected testdata for StubBuilderTestGenerated
2015-04-29 19:19:40 +02:00
Dmitry Jemerov
f61a4a15cc
rename "isTrait" to "isInterface": update test data
2015-04-29 16:50:20 +02:00
Dmitry Jemerov
f93eeeb563
fix tests by adding missing 'init' keywords to testdata
2015-04-29 14:07:05 +02:00
Alexander Udalov
fe602d34ce
Support type annotations in cls stub builder
...
Also add test on decompiler
2015-04-29 01:03:56 +03:00
Valentin Kipyatkov
6a2cc66eb1
Got rid of isProbablyNothing in stubs + fixed exception on some files on indexing stubs
2015-04-02 10:10:31 +03:00
Valentin Kipyatkov
bff2b2f378
Fixed tests for stubs
2015-04-02 10:09:25 +03:00
Pavel V. Talanov
a986d913c3
Remove traces of class object constraints feature from parser, frontend, tests and psi
2015-04-01 20:09:34 +03:00
Denis Zharkov
8e69c06e5a
Adjust stub-builder, decompiler and renderer to new PSI structure
...
of primary ctor
2015-03-31 20:20:22 +03:00
Pavel V. Talanov
a50b218c6a
default -> companion: Replace some missed usages of "isDefault"
2015-03-17 17:10:53 +03:00
Pavel V. Talanov
06916d98c6
default -> companion: replace all mentions of default and default object
2015-03-17 15:47:39 +03:00
Pavel V. Talanov
c0a031eafe
Support secondary constructors in decompiled text
...
Build cls stubs for secondary constructors
2015-03-13 20:17:32 +03:00
Pavel V. Talanov
59f192ef90
Replace 'class object' with 'default object' in renderers and test data
...
Includes changes to decompiled text
Old syntax is used in builtins and project code for now
2015-03-06 19:36:54 +03:00
Pavel V. Talanov
48fbce9582
Refactor: process mentions of class object
...
Rename usages that refer to "default object" concept now
Test data file names are left as is
2015-03-03 20:57:08 +03:00
Pavel V. Talanov
be5f00ad1c
Update test data for various stub tests
2015-02-16 15:38:33 +03:00
Andrey Breslav
0f0f205248
Serializing information about star projections
2015-02-02 19:52:02 +03:00
Andrey Breslav
06c5be6489
Fix tests: No dangling annotations in stubs
2014-12-26 15:10:13 +03:00
Pavel V. Talanov
e20dd42aa4
Refactor stubs:
...
Convert all interface classes to kotlin and move them into one file
Convert some of Impl classes
Fix typo: hasValOrValNode
Extract ModifierMaskUtils
Minors
2014-12-21 14:23:24 +03:00
Andrey Breslav
28b466d069
Parsing dynamic types
2014-12-01 20:43:37 +03:00
Valentin Kipyatkov
b22233d378
Corrected test data for stub tests
2014-11-24 20:11:25 +03:00
Pavel V. Talanov
915bb208f0
Add test for failing assertion in JetPropertyStub.createStub
...
Test for eec6fbb205
Delayed because test data was causing reindex of the whole project
2014-07-10 15:58:03 +04:00
Pavel V. Talanov
b4b24262a0
Build stubs for insides of local objects and classes
2014-05-21 16:50:59 +04:00
Pavel V. Talanov
e33144f89a
Define toString() for stub impl classes via reflection
...
Update outdated test data for stub builder test
2014-05-21 16:50:55 +04:00
Pavel V. Talanov
eb27020340
Stubs: reduce the amount of boilerplate code
...
Extract a common type for placeholder stub elements
2014-05-21 15:37:59 +04:00
Pavel V. Talanov
5bc8cc1f9a
Stub tests: test for parameters with fq name
2014-03-24 17:51:53 +04:00
Pavel V. Talanov
ece6c8ebfe
Stubs tests: treat NO_NAME_FOR_LAZY_RESOLVE specially
2014-03-24 17:51:40 +04:00
Pavel V. Talanov
fd5aea7c14
Refactor: use generated approach for stubs test
...
Remove meaningless assertion
Add comment to NotStorePropertyFromDelegate test
2014-03-24 17:06:07 +04:00