Pavel Mikhailovskii
fd07f7f43c
[FIR] KT-60427 Don't generate outerType attributes for non-inner classes in FirElementSerializer
2023-07-19 15:27:03 +00:00
Ivan Kylchik
ca8db7d0b8
[IR] Move toIrConst method into common IrUtils file
...
This method is used not only in IR interpreter, so it makes sense to
move it.
2023-07-19 15:12:54 +00:00
Svyatoslav Scherbina
f18c6755cc
Native: fix runtime compilation against older glibc versions
...
Replace `#include <inttypes.h>` with `cinttypes`.
Improve other includes in the same file.
^KT-58864
Co-authored-by: Alexander Shabalin <Alexander.Shabalin@jetbrains.com >
2023-07-19 14:41:51 +00:00
Artem Kobzar
e4bdd3560c
[K/JS] Change order of exported properties definition for non ES-classes compilation ^KT-60131 Fixed
2023-07-19 14:33:19 +00:00
Yahor Berdnikau
dc5660d98c
[Gradle] Add 'validatePlugins' tasks for Gradle plugin dependencies
...
Gradle 8 has removed "validate-external-gradle-plugin" plugin which we
used before to run validate task inputs proper annotations.
With this change, every Gradle dependency that is not published as a
Gradle plugin but uses Gradle API types is also running
'validatedPlugins' task registered manually via a build script.
^KT-59827 Fixed
2023-07-19 13:36:03 +00:00
Yahor Berdnikau
f5889bcc6c
[Gradle] Update plugin variant used test
2023-07-19 13:36:03 +00:00
Kirill Rakhman
63374e870d
[Tests] Specify ticket number in test mute reason
...
#KT-60136
2023-07-19 13:34:58 +00:00
Kirill Rakhman
97024d9ccb
[FIR] Resolve array literal argument for non-primitive-array parameter as arrayOf call in annotation calls
...
This allows us to properly complete array literals arguments of
annotation calls fixing several false-negative type mismatch errors
as well as enabling the inference of generic type arguments.
#KT-59581 Fixed
#KT-58883 Fixed
2023-07-19 13:34:58 +00:00
Kirill Rakhman
e69b695efd
[FIR] Introduce common super type for context dependent resolution modes
2023-07-19 13:34:58 +00:00
Kirill Rakhman
ff6b3350ae
[FIR] Resolve array literal with non-primitive-array expected type as arrayOf call
...
This lets us properly complete the call which fixes some issues with
false-positive type mismatches.
This change doesn't apply to array literals in annotation calls yet
because they are resolved as context-dependent.
This will be adapted in a following commit.
#KT-59581
2023-07-19 13:34:58 +00:00
Marco Pennekamp
4ead02271b
[FIR] Move TrackableModuleInfo to the common frontend
...
- FIR-specific parts of the Kotlin IntelliJ plugin depend on
`TrackableModuleInfo`, so it should be part of the common frontend.
2023-07-19 13:03:51 +00:00
Roman Golyshev
5e30adec06
KTIJ-26276 [Analysis API] Do not consider single aliased import from the same package as unused
...
Even when the aliased import comes from the same package, it cannot be
removed, because it will break the code
Also, add more tests for the imports coming from the same package
^KTIJ-26276 Fixed
2023-07-19 12:40:57 +00:00
Dmitriy Novozhilov
8acf6b1bd0
Advance bootstrap to 1.9.20-dev-6963
2023-07-19 12:16:31 +00:00
Dmitrii Gridin
d0854d5b45
[FIR] propagate copy of original ConeKotlinType to anonymous functions to avoid concurrent modification
...
It is required to avoid leakage of annotations instance from
the original type
It should be enough to just create a new instance of an annotation
without a deep copy, because transformer shouldn't touch it
^KT-60387 Fixed
2023-07-19 11:50:12 +00:00
Dmitrii Gridin
51b9059123
[FIR] generate copy builder for annotation
...
^KT-60387
2023-07-19 11:50:12 +00:00
Dmitrii Gridin
b59e66c217
[LL FIR] add test on annotation type copy
...
^KT-60387
2023-07-19 11:50:12 +00:00
Kirill Rakhman
987867fe12
[FIR2IR] Fix crash caused by unresolved annotation argument in deserialized class
...
#KT-60181 Fixed
2023-07-19 11:07:11 +00:00
Artem Kobzar
b1884456b8
[K/JS] Fix initialization issue for objects which annotated with @JsExport and contain nested classes
...
Merge-request: KT-MR-11146
Merged-by: Artem Kobzar <Artem.Kobzar@jetbrains.com >
2023-07-19 10:41:25 +00:00
Artem Kobzar
69c8942462
[K/JS] Remove trivial JS constructors from JS AST
2023-07-19 10:41:04 +00:00
Dmitrii Gridin
4366164b65
[FIR] ConeAttributes: fix plus method
...
The 'plus' method was actually creating a new 'ConeAttributes' with
only one new attribute due to a typo inside 'buildList'
^KT-60451
^KT-60504
2023-07-19 10:40:03 +00:00
Kirill Rakhman
c605cb9855
[FIR2IR] Align object receiver generation with K1
...
#KT-59548 Fixed
2023-07-19 10:39:41 +00:00
Dmitrii Gridin
14327d51ed
[LL FIR] invalidateAfterInBlockModification: do not treat adding of body as in-block modification
...
It is an out-of-block modification because some diagnostics depend
on a fact of a body's existence
^KT-60518
2023-07-19 10:32:10 +00:00
Dmitrii Gridin
5f24ad114c
[LL FIR] AbstractInBlockModificationTest: add more tests
...
^KT-60518
2023-07-19 10:32:10 +00:00
Dmitrii Gridin
f0d8a1cbe9
[LL FIR] AbstractInBlockModificationTest: cover getNonLocalReanalyzableContainingDeclaration
...
^KT-60518
2023-07-19 10:32:10 +00:00
Dmitrii Gridin
c2fd245ca1
[LL FIR] getSelectedElement should return PsiElement
...
^KT-60518
2023-07-19 10:32:10 +00:00
Ivan Kochurkin
5f1e2764c3
[FIR] Fix some missing EXPECTED_DECLARATION_WITH_BODY
2023-07-19 10:14:08 +00:00
Ivan Kochurkin
8f4a580c17
[FIR] Report EXPECTED_CLASS_CONSTRUCTOR_DELEGATION_CALL
...
^KT-59069 Fixed
2023-07-19 10:14:08 +00:00
Vladimir Sukharev
f7269eb384
[FIR2IR] Rework reordering condition to better handle synthetic class delegation fields
...
^KT-60243
Merge-request: KT-MR-11125
Merged-by: Vladimir Sukharev <Vladimir.Sukharev@jetbrains.com >
2023-07-19 09:59:53 +00:00
Mikhail Glukhikh
66bbb9582c
K1/K2: split incremental compilation tests properly (relates to KT-59171)
2023-07-19 09:34:58 +00:00
Yahor Berdnikau
faa74d124f
[Gradle] Fix kapt tests compatability with Gradle 8.0
...
^KT-59588 Fixed
2023-07-19 08:14:50 +00:00
Anastasiia Spaseeva
61a9dcd8e6
Disable space warmups
...
#Related KTI-1043
2023-07-19 07:43:20 +00:00
Bogdan Mukvich
3aee0ab994
Add SBOM for gradle plugins
...
^KTI-1299
2023-07-19 06:57:32 +00:00
Bogdan Mukvich
b6e8937077
Use root document supplier field value for project modules in SBOM
...
KTI-1301
2023-07-19 06:55:19 +00:00
Mikhail Glukhikh
08222c83cf
K1/K2: set language version explicitly in Native tests pipeline
2023-07-19 06:46:53 +00:00
Dmitrii Gridin
7620289f6f
[FIR] fix contract violation from meta annotations
...
^KT-60448 Fixed
2023-07-18 16:50:25 +00:00
Dmitrii Gridin
480c794444
[FIR] drop redundant JavaTypeParameterStack usage from Java annotations
...
It is safe just to use `JavaTypeParameterStack.EMPTY`
as Java annotations are not expected to use containing type parameters
^KT-59342
2023-07-18 16:48:53 +00:00
Dmitrii Gridin
32ad4380b3
[FIR] make java annotation mapping lazily
...
to avoid contract violations from getDeprecation
^KT-59342 Fixed
^KT-60520
2023-07-18 16:48:53 +00:00
Ivan Kylchik
4f92e7c48c
[IR] Rename IrTypeTransformerVoid to IrTypeTransformer
...
This naming is more consistent with already existing
`IrElementTransformerVoid` and `IrElementTransformer`
2023-07-18 15:42:11 +00:00
Artem Kobzar
41f27d19b5
[K/JS, K/Wasm] Generate star imports for external objects with the @JsModule annotation for ES modules
2023-07-18 15:36:19 +00:00
Alexander Korepanov
e61a11f0a3
[JS FIR] Fix review comments
2023-07-18 14:02:30 +00:00
Alexander Korepanov
08d158f901
[JS FIR] Support JS module system FE diagnostics
...
Support CALL_TO_JS_MODULE_WITHOUT_MODULE_SYSTEM diagnostic
^KT-59377 Fixed
Support CALL_TO_JS_NON_MODULE_WITH_MODULE_SYSTEM diagnostic
^KT-59381 Fixed
Support CALL_FROM_UMD_MUST_BE_JS_MODULE_AND_JS_NON_MODULE diagnostic
^KT-59417 Fixed
2023-07-18 14:02:30 +00:00
Alexander Korepanov
30b012839c
[JS FIR] FirJsModuleOnVarPropertyChecker.kt -> FirJsModuleChecker.kt
2023-07-18 14:02:30 +00:00
Alexander Korepanov
6034d32d7c
[JS FIR] Support DYNAMIC_NOT_ALLOWED diagnostic
...
^KT-59384 Fixed
2023-07-18 14:02:30 +00:00
Alexander Korepanov
39fba56de9
[JS FIR] Support PROPERTY_DELEGATION_BY_DYNAMIC diagnostic
...
^KT-59406 Fixed
2023-07-18 14:02:30 +00:00
Alexander Korepanov
f6b7a07efe
[JS FIR] Support EXTERNAL_INTERFACE_AS_REIFIED_TYPE_ARGUMENT diagnostic
...
^KT-59416 Fixed
2023-07-18 14:02:30 +00:00
Alexander Korepanov
760320a11b
[JS FIR] Move FirJsExternalArgumentCallChecker to expression checkers
2023-07-18 14:02:30 +00:00
Alexander Korepanov
f1fc3f1cf5
[JS FIR] Move FirJsDynamicCallChecker to expression checkers
2023-07-18 14:02:30 +00:00
Dmitriy Novozhilov
45b1c33ed8
[FIR2IR] Make some utility functions inline
...
Those utilities are commonly used and effectively just call passed
lambda with some preparations
2023-07-18 13:06:15 +00:00
Dmitriy Novozhilov
ccb0d3cb0c
[FIR2IR] Refactor signatures of Fir2IrConversionScope.withXxx functions
...
Usually functions like `withSomething` are considered to return the value
of lambda which is passed to it, not one of its arguments
2023-07-18 13:06:15 +00:00
Dmitriy Novozhilov
0b502f08d5
[IR] Provide default implementations of symbol factories in SymbolTableExtension
2023-07-18 11:51:29 +00:00