Commit Graph

98961 Commits

Author SHA1 Message Date
Alexander Udalov 1cb77a47ec Fir2Ir: extract error about unsupported mutation 2023-02-22 22:40:34 +00:00
Alexander Udalov 22b4b29292 IR: make most properties mutable 2023-02-22 22:40:34 +00:00
Alexander Udalov d2938e732a IR: remove IrTypeOperatorCall.typeOperandClassifier 2023-02-22 22:40:34 +00:00
Alexander Udalov 42daeaaa80 IR: remove IrCallableReference.referencedName
It was added in 66da676b9e to avoid dependency on descriptors, but now
it doesn't use descriptors anyway, so it's better to inline it than have
it in the interface.
2023-02-22 22:40:33 +00:00
Alexander Udalov d286409b76 IR: make IrComposite.isTransparentScope an extension 2023-02-22 22:40:33 +00:00
Sergey.Shanshin 63025030e3 [KxSerialization] Fix SERIALIZER_NOT_FOUND diagnostic for enums
Fixes #KT-56738

Merge-request: KT-MR-8938
Merged-by: Sergey Shanshin <Sergey.Shanshin@jetbrains.com>
2023-02-22 19:38:18 +00:00
Ilya Goncharov 4ccad00c11 [Gradle, JS] Force enabled js compiler legacy to prevent problems in daemon 2023-02-22 13:56:15 +00:00
Pavel Mikhailovskii 7700484a16 [AA] Fix conversion of annotation values 2023-02-22 13:55:50 +00:00
Yahor Berdnikau 40a4845541 Use KotlinNativeCompilerOptions in KotlinNativeCompile task
^KT-53108 Fixed
2023-02-22 13:03:00 +00:00
Yahor Berdnikau 96316a4016 Generate KotlinNativeCompilerOptions Gradle DSL
^KT-53108 In Progress
2023-02-22 13:02:59 +00:00
Ilmir Usmanov 68841fa031 Minor. Regenerate tests 2023-02-22 12:45:03 +00:00
Ilmir Usmanov 6be734c27e JVM: Remove inplace arguments before state-machine building
#KT-56258 Fixed
2023-02-22 12:45:03 +00:00
Vladimir Dolzhenko 3e99807436 Add ability to provide specific AbsentDescriptorHandler
#EA-457188

Merge-request: KT-MR-8900
Merged-by: Vladimir Dolzhenko <Vladimir.Dolzhenko@jetbrains.com>
2023-02-22 12:44:46 +00:00
Dmitrii Gridin 41278d0797 [SLC] drop redundant AnnotatedPropertyWithSites.fir.java
^KT-56842
2023-02-22 12:39:31 +01:00
Ilya Goncharov 258208731b [Gradle, JS] Disable adding dom-api-compat as default dependencies 2023-02-22 11:00:15 +00:00
Ilya Goncharov 1b7ea022e6 [Gradle, JS] Fix test with not included stdlib dependency with disabled dom-api-compat 2023-02-22 11:00:14 +00:00
Ilya Goncharov 9073a7b6b0 [Gradle, JS] Not add dom-api-compat if stdlib default dependency is disabled 2023-02-22 11:00:14 +00:00
Ilya Goncharov a391db3127 [Gradle, JS] Fix hierarchical module test 2023-02-22 11:00:14 +00:00
Ilya Goncharov afda1669d7 [Gradle, JS] Error warning mode 2023-02-22 11:00:13 +00:00
Ilya Goncharov f510bb77c8 [Gradle, JS] Fix incremental backend test 2023-02-22 11:00:13 +00:00
Ilya Goncharov d1768029b4 [Gradle, JS] Add test on dom-api-compat 2023-02-22 11:00:13 +00:00
Ilya Goncharov 67346f7913 [Gradle, JS] Revert Gradle integration tests about dom-api-compat 2023-02-22 11:00:12 +00:00
Ilya Goncharov b9cf47858d [Gradle, JS] Add module kotlin-dom-compat-api as dependency with opt-out
This reverts commit c73b6ac352.
2023-02-22 11:00:12 +00:00
Ilya Goncharov b6686d4ecb [Gradle, JS] Codeowners of kotlin-dom-api-compat
This reverts commit 680f644265.
2023-02-22 11:00:12 +00:00
Ilya Goncharov 229fd73b38 [Gradle, JS] Regenerate API stdlib
This reverts commit b4c0cab22a.
2023-02-22 11:00:11 +00:00
Ilya Goncharov 9b4821be28 [Gradle, JS] Add module dom-api-compat
This reverts commit ba8cc877fd.
2023-02-22 11:00:11 +00:00
Pavel Mikhailovskii 492a161d2c KT-56842 [SLC] Don't mark primitive context receiver parameters with @NotNull 2023-02-22 10:15:19 +00:00
Pavel Mikhailovskii de1927abb6 KT-56835 [SLC] Mark property$delegate fields as final and @NotNull 2023-02-22 09:40:32 +00:00
Ilya Goncharov 6ac562a19d [Gradle, JS] Remove redundant runtime attribute to compileClasspath in test 2023-02-21 19:35:18 +00:00
Denis.Zharkov 66eb29962a K2: Add minor clarification comment to FirDeclarationsResolveTransformer 2023-02-21 18:39:40 +00:00
Denis.Zharkov 3f052af517 K2: Propagate explicit getter type to the property without initializer
In K1, we have the rules like:
- if there's explicit type of a property, then use it
- if there's an initializer, obtain its expression-type
- Otherwise, use getter's return type

The case when getter's type is implicit is handled at
FirDeclarationsResolveTransformer.transformProperty

^KT-56707 Fixed
2023-02-21 18:39:40 +00:00
Denis.Zharkov c09607c791 K2: Minor. Reformat and clean up a couple of transformers
`@Suppress("UNCHECKED_CAST")` became redundant there
2023-02-21 18:39:40 +00:00
Denis.Zharkov bdb1e28912 K2: Minor. Simplify condition at FirDeclarationsResolveTransformer
Just to avoid double negation at !hasNonDefaultAccessors
2023-02-21 18:39:39 +00:00
Artem Kobzar 775da5d3d2 [K/JS] Fix publishing of the stdlib compiled with the legacy js compiler 2023-02-21 18:10:15 +00:00
Pavel Mikhailovskii d81170fbcc KT-56840 [SLC] Don't mark primitive-backed types with @NotNull 2023-02-21 17:29:16 +00:00
Ilya Goncharov bcb517d66b [Gradle, JS] Distinguish cache directories for js ir incremental compilation
[Gradle, JS] Make cleanOutputsAndLocalState as member method

^KT-56765 fixed
2023-02-21 16:37:37 +00:00
Pavel Mikhailovskii 81746e5aa1 KT-56508 Add a test 2023-02-21 16:22:26 +00:00
Ilmir Usmanov bfa2937fb8 FIR2IR: Do not add fake override if the member is overridden
#KT-56398 Fixed
2023-02-21 17:18:01 +01:00
Alexander Korepanov 3c9d653595 [JS IR] Ignore unbound symbols in IC infrastructure
The IR linker is responsible for detecting unbound symbols,
 if it skips them for some reason, IC infrastructure must not fail
 with unbound symbols exceptions. Anyway, the IR validator
 verifies later if there are unbound symbols in
 reachable IR and generates the corresponding error.

^KT-56602 Fixed
2023-02-21 14:46:44 +00:00
Yahor Berdnikau ff22f456a0 Fix KGP integration tests tasks run tests with other tags
Before this change specific test task (for example 'kgpJvmTests') will
run also test cases that included into test class annotated with
"JvmKGP" tag, but test case itself annotated with, for example,
"OtherKGP". Now specific test tasks should only run tests for given test
 tag.
2023-02-21 14:42:39 +00:00
Nikita Bobko 9a865e4c55 [FE 1.0] Issue a warning if expect and actual are declared in the same module
The commit is based on b09561c3c3
Co-authored-by: Dmitriy Novozhilov <dmitriy.novozhilov@jetbrains.com>

^KT-40904 Fixed
^KT-55177 Fixed
Review: https://jetbrains.team/p/kt/reviews/8731

True negative test already exist:
`compiler/testData/diagnostics/tests/multiplatform/hmpp/multiplatformCompositeAnalysis/intermediateWithActualAndExpect.kt`
2023-02-21 14:45:46 +01:00
Nikita Bobko 456605542c Make it possible to run hmpp tests with ENABLE_MULTIPLATFORM_COMPOSITE_ANALYSIS_MODE
In scope of KT-40904 KT-55177
Review: https://jetbrains.team/p/kt/reviews/8731

In order to make it possible to run hmpp tests with
`ENABLE_MULTIPLATFORM_COMPOSITE_ANALYSIS_MODE`, a dependency manager
must be implemented. This commit implements some basic dependency
manager. I'm not sure in its correctness because
`CommonDependenciesContainer` is an awkward API, but this dependency
manager works for my cases.

Why: I need hmpp + `ENABLE_MULTIPLATFORM_COMPOSITE_ANALYSIS_MODE`
infrastructure to cover `ExpectActualInTheSameModuleChecker` (I will add
the checker in the next commit) with tests. The checker couldn't be
covered with regular hmpp tests because regular hmpp tests and
`K2MetadataCompiler` run the compiler in a different way.
Contrary, `ENABLE_MULTIPLATFORM_COMPOSITE_ANALYSIS_MODE` runs the compiler in a
way `K2MetadataCompiler` does it.

I moved some tests from hmpp to `hmpp/multiplatformCompositeAnalysis`
because otherwise the tests would fail after I implement
`ExpectActualInTheSameModuleChecker` in the next commit.

Also the descriptor dumps were changed
(intermediateWithActualAndExpect.txt and
sealedInheritorsInComplexModuleStructure.txt). It happened because now
common source sets are no longer "squashed" into a single source set but
rather correct dependencies between source sets are established. And
each source set is analyzed separately (exactly like in
K2MetadataCompiler)
2023-02-21 14:45:45 +01:00
Denis.Zharkov 14ca12b50b K2: Add test for obsolete KT-56663
It was fixed via 898a9a0f2c together with
KT-53966

^KT-56663 Obsolete
2023-02-21 12:36:04 +00:00
Denis.Zharkov 0c9fad87c3 K2: Fix deserialization of upper bound of type parameter in nested class
Previously, containingDeclarationSymbol for V was set to the outer class
BaseRoot, so its upper bounds was computed to the ones from TNested
at org.jetbrains.kotlin.fir.resolve.calls.CreateFreshTypeVariableSubstitutorStageKt.getTypeParameterFromExpandedClass

^KT-56706 Fixed
2023-02-21 12:35:34 +00:00
Denis.Zharkov 9f51d3fbeb K2: Minor. Make properties private in FirTypeDeserializer 2023-02-21 12:35:34 +00:00
Svyatoslav Scherbina f206ff950c [K2/N] Ignore kt15016.kt test because it fails due to KT-56747 2023-02-21 11:52:06 +00:00
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
Anton Lakotka 1dd9751f99 [Gradle] Add mavenScope parameter to createSourcesJarAndUsageContextIfPublishable
^KT-55881 Verification Pending
2023-02-21 10:15:38 +00:00
Anton Lakotka f8e1b51f04 [Gradle] Rename publishableSources to isSourcesPublishable
^KT-55881 Verification Pending
2023-02-21 10:15:38 +00:00
Anton Lakotka 5b0a9c7a55 [Gradle] Update kotlin-gradle-plugin-api.api
^KT-55881 Verification Pending
2023-02-21 10:15:37 +00:00