Alexander Udalov
b4d65fe5cd
JVM: remove obsolete code for reporting JVM backend diagnostics
...
The last remaining usages from diagnostic tests were removed in previous
commits.
2024-03-15 14:39:56 +00:00
Vladimir Dolzhenko
8b7ca9527a
Inject checkCanceled calls to improve responsiveness
...
#KTIJ-28688
Co-authored-by: Dmitrii Gridin <dmitrii.gridin@jetbrains.com >
Merge-request: KT-MR-14866
Merged-by: Vladimir Dolzhenko <Vladimir.Dolzhenko@jetbrains.com >
2024-03-11 20:47:30 +00:00
Alexander Udalov
2f056fe155
JVM: remove StubClassBuilder and its usage
...
After legacy light classes were removed, the only remaining usage was in
KotlinLightClassBuilderFactory where we ran JVM backend in the
LIGHT_CLASSES mode, and that was only used from diagnostic tests to
report JVM backend diagnostics.
We don't actually need to build stubs here, so we can just use ASM's
class writer, which means that StubClassBuilder and all its dependencies
can be removed.
2024-03-11 18:03:49 +00:00
Alexander Udalov
28797a31b4
JVM: refactor JvmDefaultMode, remove/rename some entries
...
- remove ENABLE/COMPATIBILITY because they can no longer be used
- remove forAllMethodsWithBody because its behavior is now equivalent to
isEnabled
- inline isCompatibility
- inline DEFAULT
- rename ALL_INCOMPATIBLE -> ALL
2024-02-06 17:18:44 +00:00
Alexander.Likhachev
60080e8bb8
[Build] Remove redundant trove4j compileOnly dependencies
...
^KTI-1135 In Progress
2024-01-10 11:29:25 +00:00
Kirill Rakhman
81517a3d29
[FIR] Set targets of annotation classes in FirJavaElementFinder
...
#KT-60504 Fixed
2023-12-07 18:29:45 +00:00
Ivan Kochurkin
1827df82c4
Removed useless as casts from compiler code
...
It allows compiling code with K2 and enabled `-Werror`
2023-10-24 20:59:56 +00:00
Nikolay Lunyak
ec9cb8beb6
[FIR] Rename JvmNames -> JvmStandardClassIds
...
This is more consistent with the code of
the common compiler checkers.
It would be nice to refactor the contents
of this object further, but it's out
of scope of the current branch.
^KT-54596
2023-09-19 22:14:09 +00:00
Bogdan Mukvich
7b00323b89
[Build] Update guava
...
Fix some reports from "Show Vulnerable Dependencies"
^KTI-1342
2023-08-25 14:10:37 +00:00
Jinseong Jeon
7f1424737e
LC: rework modality of enum class
...
It is abstract if it has abstract member.
It is final if it doesn't have enum entries that need subclass.
Otherwise, it is open (i.e., no modifier)
^KT-57567 Fixed
2023-06-23 16:19:06 +02:00
Marco Pennekamp
c00eb050ce
[SLC/ULC] KTIJ-25335 Avoid generating fields with special names
...
- Due to the fixes for KTIJ-23584, when calling the UAST conversion
`convertDeclarationOrElement` from `BaseKotlinConverter` (intellij
project) for an SLC/ULC property, `convertDeclaration` failed because
the declaration is "special". This caused `convertPsiElement` to be
tried instead, which also returned `null`, causing the "failed to
convert element" exception described in KTIJ-25335.
- In parallel to the solution for KTIJ-23584, which fixed the special
names issue for functions, this commit skips UAST field generation for
properties with special names.
^KTIJ-25335 fixed
^KTIJ-24121 fixed
2023-06-23 09:26:57 +00:00
Jinseong Jeon
618d6526a7
Rename KtLightClassForScript to reuse it for common interface between LCs
2023-06-21 11:14:15 +02:00
Alexander Udalov
fb900d2e2a
JVM: remove most usages of JvmTarget.JVM_1_6
2023-05-19 13:24:00 +00:00
Jinseong Jeon
41473a948d
SLC: implement PsiAnnotation#find(Declared)AttributeValue
...
^KT-58448 Fixed
2023-05-15 14:16:14 +02:00
Roman Golyshev
d4cffb8a5a
[213] Switch to 213 platform
...
KTI-1114
2023-04-21 13:19:04 +00:00
Dmitrii Gridin
7d37bb1f78
[LC] FakeFileForLightClass: drop stub access from equals/hashCode
...
^KT-57857 Fixed
2023-04-11 09:19:39 +00:00
Jinseong Jeon
0ac3fae9ab
LC: commonize facade for multi-file class
2023-03-29 18:51:03 +02:00
Dmitrii Gridin
9129235079
[LC] add missing parent to implementsList and extendsList
...
^KT-56613
2023-03-01 10:43:03 +00:00
Dmitrii Gridin
58dc93da90
[LC] do not store name identifier as property
...
^KT-56613
2023-03-01 10:43:02 +00:00
Pavel Mikhailovskii
9204f8162e
[SLC] Fix modifiers for @JvmStatic methods in interfaces
2023-02-23 17:04:22 +00:00
Jinseong Jeon
88b07f5287
SLC: keep annotations on type when converting to PsiType
...
^KT-55815 Fixed
2023-02-09 19:53:45 +01:00
Dmitriy Novozhilov
bd26c29229
[FIR] Resolve arguments of error types during type resolution
2023-01-12 17:45:06 +00:00
Dmitrii Gridin
461682a797
[LC] createField: avoid body resolve in case of psi declaration
2023-01-06 21:09:40 +00:00
Roman Efremov
e5d5cbc7a3
Generate Enum.getEntries method in ultra light classes
...
^KTIJ-23530 Fixed
2022-12-27 14:41:52 +00:00
Dmitrii Gridin
88f1f74aec
[ULC] fix descriptor leak from synthetic members
...
^KT-55604 Fixed
2022-12-21 19:08:56 +00:00
Dmitrii Gridin
34e4645385
[ULC] avoid resolve from KtUltraLightClassModifierList.hasModifierProperty in most cases
...
^KT-55445 Fixed
2022-12-13 18:18:00 +00:00
Jinseong Jeon
5f986fd467
ULC: fix PsiMethod#getThrowsList for accessors
...
^KTIJ-17761
2022-12-11 15:22:12 +00:00
Dmitrii Gridin
cba70d70a7
[SLC] drop hack with setParent for annotations
...
^KTIJ-23783
2022-12-06 13:40:44 +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
Jinseong Jeon
8d8d0d9922
SLC: add marker interface for collection inheritor
2022-10-27 14:41:24 +02:00
Jinseong Jeon
8016225519
ULC: make file/class names match
2022-10-27 10:36:40 +02:00
Jinseong Jeon
dbf0ba442a
(U|S)LC: fix getText for modifier list / accessor
2022-10-19 14:17:36 +02:00
Jinseong Jeon
e1344968ec
(S|U)LC: fix getTextOffset and getTextRange for modifier list of accessors
...
in a similar way 36e1149e did for property accessors
2022-10-19 14:17:36 +02:00
Jinseong Jeon
3eb68a6ee8
S/LC: fix default visibility of constructor of sealed class
2022-09-09 14:38:12 +02:00
Dmitry Gridin
e58b98bb5c
[lc] KotlinAsJavaSupportBase: implement getLightClassForScript
...
^KT-50241
2022-09-08 13:47:39 +00:00
Dmitry Gridin
46548e5443
[lc] KotlinAsJavaSupportBase: implement getLightClass
...
add more caching
^KT-50241
2022-09-08 13:47:38 +00:00
Dmitry Gridin
924dd38144
[lc] introduce KotlinAsJavaSupportBase with new common facade logic
...
^KT-53543
2022-08-29 11:51:42 +00:00
Dmitry Gridin
5be31e575c
[lc] extract common code to KtLightClassForFacadeBase
...
^KT-53543
2022-08-29 11:51:41 +00:00
Dmitry Gridin
acfbe30f7c
[lc] drop redundant PsiManager argument from KtLightClassForFacadeBase
...
^KT-53543
2022-08-29 11:51:40 +00:00
Dmitry Gridin
9b925efdaf
[light classes] ultraLightClass: cleanup code
...
^KT-53097
2022-08-01 13:56:39 +00:00
Dmitry Gridin
e8d74d8224
[light classes] convert jvmDefaultMode from KtUltraLightSupport to extension
...
^KT-53097
2022-08-01 13:56:38 +00:00
Dmitry Gridin
716efa60df
[light classes] drop redundant receiver from createTypeFromCanonicalText
...
^KT-53097
2022-08-01 13:56:38 +00:00
Dmitry Gridin
1514d5f563
[light classes] drop redundant KtLightClassForSourceDeclaration#forceUsingOldLightClasses
...
^KT-53097
2022-08-01 13:56:37 +00:00
Dmitry Gridin
be45a329d6
[light classes] drop redundant KtLightSimpleModifierList
...
^KT-53097
2022-08-01 13:56:36 +00:00
Dmitry Gridin
9606d49379
[light classes] drop redundant KtUltraLightSupport from annotations
...
^KT-53097
2022-08-01 13:56:35 +00:00
Dmitry Gridin
1708b4fe48
[light classes] move light-classes-base module to analysis
...
^KT-53097
2022-08-01 13:56:34 +00:00
Dmitry Gridin
651d4d8be0
[light classes] move getParentForLocalDeclaration to light-classes-base
...
^KT-53097
2022-07-19 15:42:08 +00:00
Dmitry Gridin
0e17d9b452
[light classes] extract KotlinLightClassFactory to service
...
^KT-53097
2022-07-19 15:42:07 +00:00
Dmitry Gridin
81a5b4070d
[light classes] move KtLightMethodImpl to light-classes-base module
...
^KT-53097
2022-07-19 15:42:06 +00:00
Dmitry Gridin
024c40a3fa
[light classes] move checkIsMangled to light-classes-base module
...
^KT-53097
2022-07-19 15:42:05 +00:00