Dmitriy Novozhilov
671083c701
[Serialization] Implement serialization checker for K2 version of plugin
...
^KT-53178 Fixed
2022-09-07 07:57:38 +00:00
Dmitriy Novozhilov
194741b96b
[FIR] Remove incorrect FirClassSymbol<*>.superConeTypes utility
...
Replace all usages with member `FirClassSymbol.resolvedSuperTypes`
2022-09-07 07:57:37 +00:00
Dmitriy Novozhilov
a6d3c6e5c6
[Serialization] Suppress OPT_IN errors in all diagnostic tests
2022-09-05 10:20:06 +00:00
Dmitriy Novozhilov
84b8ab1f9c
[Serialization] Add DiagnosticsTests for FIR
2022-09-05 10:20:06 +00:00
Dmitriy Novozhilov
a2ffba275c
[Serialization] Migrate all tests to new test infrastructure
2022-09-05 10:20:05 +00:00
Ilya Muradyan
b801d963a1
[Scripting] Fix obtaining virtual file for getting compilation configuration
2022-08-31 20:51:06 +00:00
Nikolay Krasko
01f567a16d
Disable yarn and npm tasks from the build when tests are not active
...
Kotlin build shouldn't depend on npm during while deploy artefacts tasks
^KTI-887 Fixed
^KT-53687 Related
2022-08-30 22:15:16 +00:00
Pavel Mikhailovskii
18e61315f4
KT-27936 Generate InnerClasses attributes
2022-08-23 22:06:10 +00:00
soarex
4a8eec8166
Fix test environment setup in atomicfu plugin
...
Co-authored-by: soarex <soarex16@gmail.com >
Merge-request: KT-MR-6915
Merged-by: Maria Sokolova <maria.sokolova@jetbrains.com >
2022-08-23 20:58:31 +00:00
Dmitriy Novozhilov
cc00dcc038
[Serialization] Reorganize module structure
2022-08-22 17:23:18 +03:00
Nikita Bobko
2a4f3f41aa
2/5 Replace source dependency on kotlin-reflect with binary dependency
...
Review: https://jetbrains.team/p/kt/reviews/6753
Meaningful semantic change was splitted into 5 commits to simplify the
change review. Sinle commit would be too big.
Why replace source to binary: to get rid of kotlin-reflect in Kotlin
plugin artifact KTIJ-22276
Note: Kotlin Maven artifacts (./gradlew publish) changed their
dependency on kotlin-reflect
2022-08-22 15:43:49 +02:00
Nikita Bobko
0874fb71c6
Replace all kotlin-reflect-api dependencies with kotlin-reflect
...
Review: https://jetbrains.team/p/kt/reviews/6753
Why: I'm going to replace source dependency on kotlin-reflect with
binary dependency. Normalize reflect dependency before global
processing.
2022-08-22 15:43:11 +02:00
Nikita Bobko
8f79e833a8
Drop all redundant kotlin-reflect, kotlin-reflect-api dependencies
...
Review: https://jetbrains.team/p/kt/reviews/6753
All redundant I managed to find, of course.
Why: I'm going to process all reflect dependencies in the next commits.
Cleanup reflect dependency before processing.
They are redundant because:
1. if `compileOnly` then compilation didn't break after dropping the
dependency
2. if `test*` then tests didn't break after dropping the dependency.
3. `analysis/analysis-api-fir/analysis-api-fir-generator/build.gradle.kts`
`compiler/fir/checkers/checkers-component-generator/build.gradle.kts`
Drop `implementation(project(":kotlin-reflect-api"))` because the
module already depends on
`implementation(project(":kotlin-reflect"))`
4. `compiler/daemon/daemon-client/build.gradle.kts`. Drop `runtimeOnly`
because after dropping `compileOnly` compilation didn't break (so
`runtimeOnly` looks suspicious). Less safe than 1-3
2022-08-22 15:42:57 +02:00
Nikita Bobko
70ed76e0bd
Drop unused ':dist' dependency in some tests
...
Review: https://jetbrains.team/p/kt/reviews/6753
This commit doesn't fix any issue except for "cleanup". If you find a
mistake in this commit feel free to revert part of it/the whole commit
I checked every module where I drop ':dist' dependency. Tests still pass
in those modules
2022-08-22 15:42:34 +02:00
Leonid Startsev
0869dd9c92
Repair bootstrapping for wasm-ir module by removing class referencing
...
from constructor of kotlinx.serialization ir generator.
Such references may be null if plugin was applied to the module, but no
runtime was provided in current compile configuration (see added test).
2022-08-19 14:42:36 +00:00
Leonid Startsev
0b3d9ffa71
Replace ad-hoc .newRef() with .toFirResolvedTypeRef()
2022-08-19 14:42:35 +00:00
Leonid Startsev
dc7ba5d22b
Remove module-wide ObsoleteDescriptorApi opt-in
...
and remove access to .descriptor whenever possible
2022-08-19 14:42:34 +00:00
Leonid Startsev
783087a551
Add tests for value classes serialization
...
apparently they're already working in FIR
2022-08-19 14:42:33 +00:00
Leonid Startsev
89a8bdc0f6
Support enum serialization in FIR
...
for all runtime versions, re-enable optimization in IR backend
by correctly determining presence of functions in runtime.
2022-08-19 14:42:32 +00:00
Leonid Startsev
472aca1491
Tests for sealed & abstract serializable classes in FIR
2022-08-19 14:42:31 +00:00
Leonid Startsev
6b32ce76c2
Support serializable objects in FIR plugin
2022-08-19 14:42:30 +00:00
Dmitriy Novozhilov
7390d8cd54
[Build] Add reflect to runtime classpath of kotlinx.serialization tests
...
This is needed to be able to run those tests with JPS build
2022-08-19 14:42:28 +00:00
Leonid Startsev
edff4d43bf
Generate writeSelf and load constructor even if they were not created by frontend
...
which is true in case for FIR which discourages purely synthetic declarations.
2022-08-19 14:42:27 +00:00
Leonid Startsev
acd6180c30
Support generic classes in serialization FIR plugin
2022-08-19 14:42:26 +00:00
Alexander Udalov
45abea5b0a
Use platform class loader in 'kotlin' runner on JDK 9+
...
#KT-46312 Fixed
2022-08-17 22:23:10 +02:00
Sergey.Shanshin
2cb6483e8a
Added inspection for duplicating serial names in enumeration entries
...
Resolves Kotlin/kotlinx.serialization#1852
2022-08-17 20:17:22 +00:00
Leonid Startsev
c1191e141b
Re-generate copyright in obsolete tests in kotlinx.serialization
2022-08-17 15:02:38 +02:00
Leonid Startsev
18ec5d4ec1
Add additional check to IrClass.findEnumValuesMethod()
...
to avoid finding user-defined member function
2022-08-17 11:43:41 +00:00
Leonid Startsev
6893e210fb
[K2] Remove typeWithStarProjections in favor of constructStarProjectedType
2022-08-17 11:43:40 +00:00
Leonid Startsev
638665d9b0
Refactor typeWithStarProjections() so it uses FirClassSymbol instead of FirClass
...
It removes necessity to access .fir in plugins
2022-08-17 11:43:40 +00:00
Leonid Startsev
b17ead97bc
Fix incorrect class reference in polymorphic and contextual case
...
Upper bound should be used for type parameters there
2022-08-17 11:43:39 +00:00
Leonid Startsev
6a6b542ae2
Extract predicates to separate file, apply other review suggestions
2022-08-17 11:43:38 +00:00
Leonid Startsev
a4b35c5810
Refactor most of the new code, split huge GeneratorHelpers.kt appropriately
2022-08-17 11:43:37 +00:00
Leonid Startsev
c1b0ad418b
Activate MetaSerializable test and update serialization dependency
2022-08-17 11:43:37 +00:00
Leonid Startsev
b0716fe725
Adapt IR serialization plugin so it works both with FIR and old FE
...
(except some places that are not currently supported by FIR part of plugin)
2022-08-17 11:43:36 +00:00
Leonid Startsev
89329a0e1b
Introduce @FirIncompatiblePluginApi
2022-08-17 11:43:35 +00:00
Leonid Startsev
467ff30aac
Support full pipeline for basic kotlinx.serialization case:
...
FIR frontend and IR backend plugins.
Note: IR plugin is now broken for old FE, fixed in subsequent commits
2022-08-17 11:43:34 +00:00
Leonid Startsev
cefc372632
Remove BindingContext, KotlinType and *Descriptor from IR plugin dependencies
2022-08-17 11:43:34 +00:00
Leonid Startsev
6f6342dafc
Prototype of kotlinx.serialization FIR plugin:
...
Implement basic non-parameterized case
2022-08-17 11:43:33 +00:00
Mikhail Glukhikh
7333589663
K1/K2: add Enum.entries unconditionally and filter them out in tower
...
Before this commit, we added Enum.entries only in case when
LanguageFeature.EnumEntries was ON (with an exception in K1/Java case).
In this commit we add Enum.entries unconditionally, and in case
the language feature is OFF we filter them out during tower resolve.
2022-08-12 09:35:27 +00:00
Dmitriy Novozhilov
fd4aafdb75
[Lombok K2] Support @Builder and @Singular annotations
...
^KT-46959 Fixed
2022-08-11 15:22:36 +03:00
Dmitriy Novozhilov
b32f9dcac2
[Lombok K1] Support @Singular annotation
...
^KT-46959
2022-08-11 15:22:35 +03:00
Dmitriy Novozhilov
b311f0b862
[Lombok K1] Support @Builder annotation
...
^KT-46959
2022-08-11 15:22:35 +03:00
Dmitriy Novozhilov
6fde784b55
[FE 1.0] Allow generation of nested classes for java classes from plugins
2022-08-11 15:22:35 +03:00
Dmitry Gridin
4ceb170917
regenerate tests
2022-08-05 14:12:41 +02:00
Sergey.Shanshin
7a8c864c5c
Added serialization support for unsigned arrays as built-in
2022-08-05 10:09:56 +00:00
Sergey.Shanshin
c538189501
Added serialization support for the kotlin.Nothing class as built-in
2022-08-05 10:08:39 +00:00
Sergey.Shanshin
c2bdd51658
Added diagnostic for external serializers
...
Relates Kotlin/kotlinx.serialization#532
2022-08-05 09:31:58 +00:00
Dmitriy Novozhilov
70da19bd22
[Lombok K2] Fix name convention for @With on boolean fields
...
^KT-53451 Fixed
^KT-53370
2022-08-03 13:46:24 +03:00
Dmitriy Novozhilov
11f8e776af
[Lombok K2] Fix generating @With methods for final fields
...
^KT-53370
2022-08-03 13:46:24 +03:00