Egor Kulikov
694ef8e52d
[FIR] Use stubs to get context receiver list and name of label
...
Thirteenth step for ^KT-52615
Merge-request: KT-MR-8911
Merged-by: Egor Kulikov <Egor.Kulikov@jetbrains.com >
2023-02-21 10:44:02 +00:00
Egor Kulikov
d670e5a695
[FIR] Do not get expressions from contract effect list in lazy mode
...
Eleventh step for ^KT-52615
2023-02-16 17:18:10 +00:00
Egor Kulikov
32c3b0cd58
[FIR] Use stubs for creating lazy bodies of backing field initializer
...
Ninth step for ^KT-52615
Merge-request: KT-MR-8756
Merged-by: Egor Kulikov <Egor.Kulikov@jetbrains.com >
2023-02-10 10:02:39 +00:00
Egor Kulikov
8b1e508740
[FIR] Make check for dangling modifier lists use stubs
...
Seventh step for ^KT-52615
Merge-request: KT-MR-8651
Merged-by: Egor Kulikov <Egor.Kulikov@jetbrains.com >
2023-02-03 12:21:58 +00:00
Anna Kozlova
6f9cfe1943
[AA] don't treat broken code as function type parameter
...
inspired by KTIJ-23940
2023-01-17 11:50:20 +00:00
Egor Kulikov
842ad56266
[PSI] Fix highlightning hangs in libraries
...
Fixes ^KTIJ-23875
findChildrenByType was errorneously replaced with
getStubOrPsiChildrenAsList
Merge-request: KT-MR-8165
Merged-by: Egor Kulikov <Egor.Kulikov@jetbrains.com >
2023-01-16 17:24:05 +00:00
Vladimir Dolzhenko
4466b2c980
Mark KtStubElementTypes#FILE will be deleted in 1.9.0
...
#KT-53781
2023-01-08 21:43:26 +01:00
Vladimir Dolzhenko
4542b3947b
Clean up: rename Jet* to Kt*
2023-01-03 16:36:53 +01:00
Jaebaek Seo
a637626601
Handle context receiver in KtModifierListOwner.addModifierList()
...
The existing `KtModifierListOwner.addModifierList(newModifierList)`
function adds a visibility keyword (e.g., `private`) in front of the
`context(..)` modifier, which generates wrong code. This commit fixes
it.
^KTIJ-23728 fixed
2022-12-05 11:20:03 +01:00
Vladimir Dolzhenko
af08e4121d
Fix fragment element types class hierarchy.
...
They must not extend `IStubFileElementType`.
#KT-55160 Fixed
2022-11-28 15:44:37 +00:00
Anna Kozlova
abb45a0728
[AA] don't treat incomplete function as anonymous
...
^KTIJ-23672
sync anonymous function predicate with RawFirBuilder/DeclarationsConverter
2022-11-25 14:27:03 +00:00
Egor Kulikov
877e11419e
Stub updates for RawFirBuilder
...
First step for KT-52615
2022-11-18 11:40:09 +01:00
Yan Zhulanow
89c9646e2f
[FE] Restore source compatibility in KtPsiFactory
...
Prevent huge code migration in kt- release branches by returning the
previously available API in deprecated status.
2022-11-15 14:58:39 +00:00
Yan Zhulanow
ea3f550b58
[FE] Support analyzable files throughout all 'KtPsiFactory' API
...
Before, the only way of getting analyzable elements was to create an
analyzable file by using 'createAnalyzableFile()'. So made all utilities
available in 'KtPsiFactory' useless as they delegate to 'createFile()'
that always set the 'doNotAnalyze' flag.
The new behavior is to pass the 'analysisContext' instead if it is
passed to the 'KtPsiFactory' constructor.
The newly appeared API is going to be used in the Kotlin's UAST
implementation.
2022-11-11 11:28:34 +00:00
Vladimir Dolzhenko
5dc2442872
Safe reporting PSI elements in KEWA
2022-11-03 17:27:11 +00:00
Ivan Kochurkin
952274e046
[Lexer] Restore KtToken constructors without tokenId parameter
...
Mark them as @Deprecated, ^KT-54745 Fixed
2022-11-01 18:35:08 +00:00
Vladimir Dolzhenko
2ff97271e0
Fix addDeclaration in case of neigbour PsiErrorElement
...
Relates to #KTIJ-20214
2022-11-01 12:00:34 +00:00
Dmitriy Novozhilov
d423782fac
[FE 1.0] Remove usages of safeAs and cast from most of FE 1.0 modules:
...
- :core:descriptors
- :core:descriptors.jvm
- :core:deserialization
- :compiler:cli
- :compiler:frontend
- :compiler:frontend:cfg
- :compiler:frontend.java
- :compiler:frontend.common.jvm
- :compiler:psi
- :compiler:resolution
- :compiler:resolution.common
- :compiler:resolution.common.jvm
- :kotlin-reflect-api
2022-10-12 13:58:56 +00:00
Nikolay Lunyak
f578381726
[FIR] KT-46483: Forbid annotations in where Clauses
...
Merge-request: KT-MR-7208
Merged-by: Nikolay Lunyak <lunyak.kolya@mail.ru >
2022-09-28 13:38:18 +00:00
Vladimir Dolzhenko
fc8cb40a0d
Make KtFileElementType#INSTANCE final
...
#KT-53781
2022-09-19 20:34:35 +00:00
Vladimir Dolzhenko
8804742220
Revert back and deprecate KtStubElementTypes#FILE
...
Due to usages in some external tooling
#KT-53781
2022-09-19 20:34:35 +00:00
Vladimir Dolzhenko
da86e536ad
Do not swallow exception throwing IOOBE
...
#KTIJ-22746
2022-09-15 21:30:34 +00:00
Dmitriy Novozhilov
7ef81c27df
[AA] Make KotlinReferenceProvidersService and KotlinReferenceProviderContributor a project services
...
There is no need to have those services on application level
2022-09-15 17:27:20 +03:00
Vladimir Dolzhenko
298494fa08
Drop KtStubElementTypes.FILE
...
FILE elements are always registered eagerly on parser definition load
and should not be mentioned in stubElementTypeHolder interfaces.
KtFileElementType.INSTANCE was defined in 2 places, first as
getFileNodeType of KotlinParserDefinition and second is
KtStubElementTypes. In order to ensure that there are no conflicts
in stubs the platform needs to recheck these 2 declarations,
and it triggers loading of KtStubElementTypes fields. We do not need
to declare FILE element in KtStubElementTypes and may just remove this
declaration as excessive. This will delay init of KtStubElementTypes
to the moment when Kotlin files appear in indexes.
#KT-53781
2022-09-15 10:35:05 +00:00
Vladimir Dolzhenko
584eb9dfa9
Move TokenSet from KtStubElementTypes
...
KtStubElementTypes has to have only KtStubElementType fields to provide
ability to initialize stub element types lazily.
#KT-53781
2022-09-15 10:35:04 +00:00
Mikhael Bogdanov
c168a19a58
Build compiler with -Xjvm-default=all + @JvmDefaultCompatibility when needed
2022-09-14 14:40:37 +02:00
Mikhail Glukhikh
a9b8f6715b
Revert "[FE 1.0] Resolve setters through the new type inference infra"
...
This reverts commit 6e191147b9 .
2022-09-13 09:09:00 +00:00
Roman Golyshev
3f6742916a
Increment stub binary version due to externalId change
...
Follow-up to e0c2813a37
2022-09-09 18:48:30 +02:00
Vladimir Dolzhenko
e0c2813a37
Increment version due to externalId change
...
#KT-53781
2022-09-09 08:17:50 +00:00
Toshiaki Kameyama
26d4e02b7c
Allow KtPsiFactory#createModifierList to create fun modifier
...
#KTIJ-16332
2022-09-07 18:03:51 +00:00
Pavel Mikhailovskii
85ab8b4ce1
KT-53783 Prohibit "expect data object" syntax
2022-09-07 12:53:24 +00:00
Vladimir Dolzhenko
79d1ca0504
Align externalId
...
externalId for any field in stubElementTypeHolder has to be prefix (`kotlin`) + dot (`.`) + field name
#KT-53781
2022-09-06 10:52:33 +00:00
Roman Golyshev
35116696b2
Add missing @Override annotation to KtParameter
2022-08-31 12:41:44 +00:00
Denis.Zharkov
3d7969ec8f
Revert "KT-35811: Type parameter angle brackets followed by equal sign are parsed incorrectly if whitespace is missing"
...
This reverts commit 2053363def .
^KT-35811 Open
2022-08-30 11:21:50 +00:00
Denis.Zharkov
211d662708
Revert "KT-8263: Conditional operators are not parsed correctly"
...
This reverts commit ec8da2033c .
For the reason for the revert see KT-53719
^KT-8263 Open
^KT-53719 Fixed
2022-08-30 11:21:50 +00:00
Iven Krall
ec8da2033c
KT-8263: Conditional operators are not parsed correctly
2022-08-16 10:00:54 +00:00
Iven Krall
2053363def
KT-35811: Type parameter angle brackets followed by equal sign are parsed incorrectly if whitespace is missing
2022-08-16 10:00:53 +00:00
Ivan Kochurkin
c0fe14a091
Make myExpressionParsing final (Parser)
2022-08-05 13:20:41 +00:00
Ivan Kochurkin
daeb41b411
Minor fixes in parser
2022-08-05 13:20:40 +00:00
Ivan Kochurkin
1d73d4cfbf
Reduce allocations in lastDotAfterReceiver (parsing)
2022-08-05 13:20:40 +00:00
Ivan Kochurkin
cf190f0cf2
Use switch case statement instead of sequence of if comparisons in parser
2022-08-05 13:20:39 +00:00
Ivan Kochurkin
6bb2af142c
Use static initialization for token sets that are used in expect method in Kotlin parser
2022-08-05 13:20:39 +00:00
Denis.Zharkov
11a26e540e
Revert "KT-35811: Type parameter angle brackets followed by equal sign are parsed incorrectly if whitespace is missing"
...
This reverts commit a2077f9063 .
2022-08-04 17:50:00 +02:00
Denis.Zharkov
2ae2a7e442
Revert "KT-8263: Conditional operators are not parsed correctly"
...
This reverts commit 85800b4f9f .
2022-08-04 17:49:42 +02:00
Iven Krall
85800b4f9f
KT-8263: Conditional operators are not parsed correctly
2022-08-04 11:24:09 +00:00
Iven Krall
a2077f9063
KT-35811: Type parameter angle brackets followed by equal sign are parsed incorrectly if whitespace is missing
2022-08-04 11:24:08 +00:00
Ilya Kirillov
d9c4fda521
[Analysis API FIR] implement reference resolve inside KDoc
...
^KTIJ-22324 fixed
2022-07-28 01:37:53 +02:00
Victor Petukhov
6e191147b9
[FE 1.0] Resolve setters through the new type inference infra
...
^KT-48961 In progress
2022-07-22 16:03:50 +00:00
Ilya Kirillov
a6b6c79dc2
[PSI] do not throw exception on incorrect expression in KtPsiFactory.createExpressionIfPossible
2022-07-06 23:03:20 +02:00
Bart van Helvert
7bef560b6b
KTIJ-21986 Don't log non-kotlin code fragment context when it's null
...
This warning shouldn't be logged when the context is null.
2022-07-01 08:15:58 +00:00