Commit Graph

102206 Commits

Author SHA1 Message Date
Pavel Kirpichenkov 630c8e9df6 [AA, tests] Limit scopes of test libraries to their roots, add JDK_HOME
Without the fix, all libraries share the global scope for all project
libraries. JDK_HOME was used implicitly for things such as providing
Record support, but was not included as a test library/sdk.

KT-59637
2023-06-27 10:29:22 +00:00
Sergej Jaskiewicz 5b8b3644fc [IR] Reorder parameters in IrFactory#createLocalDelegatedProperty
This is to prepare for IrFactory auto-generation (KT-59308).
2023-06-27 10:22:54 +00:00
Egor Kulikov a7c1f53af8 [FIR] Correctly process invalid destructing declarations
^KTIJ-24730 fixed

Merge-request: KT-MR-10712
Merged-by: Egor Kulikov <Egor.Kulikov@jetbrains.com>
2023-06-27 09:54:01 +00:00
Bogdan Mukvich a9d0ff83cf Add SBOM publishing for kotlin wasm libraries
^KTI-1273
2023-06-27 09:02:18 +00:00
Bogdan Mukvich 4ded83d266 Add SBOM publishing for kotlin-test-js-runner
^KTI-1273
2023-06-27 09:02:18 +00:00
Bogdan Mukvich 53ce5c22ca Add SBOM publishing for kotlin-test libraries
^KTI-1273
2023-06-27 09:02:18 +00:00
Bogdan Mukvich 9cfc66ae77 Restore SBOM publishing for stdlib
^KTI-1273
2023-06-27 09:02:18 +00:00
Bogdan Mukvich acb97d8cc9 Add SBOM for gradle plugins
^KTI-1273
2023-06-27 09:02:17 +00:00
Ivan Kylchik fba0bd79ad [K2] Don't crash compiler if receiver on property wasn't evaluated
Compilation crash must be handled separately in
`convertToConstantValues` method because we still want successfully
compile common code. All constants will be evaluated later on
fir2ir phase.

#KT-59362 Fixed
2023-06-27 08:51:39 +00:00
Bogdan Mukvich 8dab53f58a Add README for ArtifactsTests
^KTI-1103
2023-06-27 08:47:14 +00:00
Bogdan Mukvich 3bb429929a Update expected poms in ArtifactsTests
^KTI-1103
2023-06-27 08:47:14 +00:00
Alexander Udalov 0625c1ea76 Minor, workaround an incremental compilation issue
After the previous commit, IC does not recompile code related to CLI
arguments parsing (likely due to KT-57919), so the resulting dist
compiler doesn't work at all, and all related tests are failing. This
"useless" override tricks the IC to recompile the class and all its
subclasses.
2023-06-27 08:34:40 +00:00
Troels Bjerre Lund 111bb461a9 CLI: Change kotlin reflection to java reflection
The command line argument parser is using between 0.25s and 0.5s
(depending on platform) on finding annotated properties. This fix
replaces the slow kotlin reflection with java reflection, which is an
order of magnitude faster.

 #KT-58183 Fixed
2023-06-27 08:34:40 +00:00
Pavel Kunyavskiy b28b0e70b6 [commonizer] Support commonizing includedForwardDeclarations in manifest
It is a new manifest property which is used only in K2, and it is
required for correct K2 processing of forward declarations.

^KT-59132
2023-06-27 08:05:52 +00:00
Alexander Udalov f3a7312ee6 K2: use ClassKind.CLASS for object literals
K1 uses CLASS, and libraries like kotlinx-metadata-jvm and
kotlin-reflect already rely on it.

 #KT-57641 Fixed
2023-06-26 20:58:55 +00:00
Alexander Udalov 1be0fcb53a Kotlinp: add "test can be unmuted" error to K2 tests 2023-06-26 20:58:55 +00:00
Sebastian Sellmair 3366366361 [Gradle] Implement initial ExternalAndroidTargetIT
Using AGP version 8.2.0-alpha09: Covering the
external Android target maintained and developed by Google.

The initial tests are intended to give basic coverage
of basic functionality (such as build and running tests), as well as
checking compatibility between AGP and KGP

^KT-59578 Verification Pending
2023-06-26 18:38:53 +00:00
Ilya Gorbunov 39e9996940 Rename js/annotations.kt to avoid duplicates in sources
The conflicting one is Annotations.kt from builtins that are merged together with js stdlib sources, thus leading to two files with the same name differing only by case.
2023-06-26 18:24:34 +00:00
Pavel Punegov 55528c571d [K/N][perf] Update wrapper to 8.1.1
benchmarkAnalyzer project could be opened as a separate project as well.
It needs an update to wrapper
2023-06-26 17:29:40 +00:00
Pavel Punegov 7927ff2a24 [K/N][perf] Update wrapper to 8.1.1
Performance project could be opened as a separate project
in the IDEA using this wrapper. To work around any issues
with the build, it should be the same version as
in the Kotlin project.
2023-06-26 17:29:40 +00:00
Pavel Punegov 854aee4bfb [K/N][perf] Set jvmTarget in the build
Set 1.8 as jvmTargets to match JavaCompile tasks
targetCompatibility version
2023-06-26 17:29:40 +00:00
Vladimir Sukharev 767cba5211 [K/N] Adjust test objc_direct.kt to pass under both K1 and K2
^KT-54610

Merge-request: KT-MR-10825
Merged-by: Vladimir Sukharev <Vladimir.Sukharev@jetbrains.com>
2023-06-26 16:57:47 +00:00
Anna Kozlova ce76db1636 [AA] introduce KtKeywordsRenderer to support nonmodifier keywords filter 2023-06-26 16:21:20 +00:00
Dmitriy Dolovov f2f935846c [JS] Fix IC tests to reflect changes in signature rendering
^KT-59486
2023-06-26 15:59:31 +00:00
Dmitriy Dolovov a17ce79088 [Native] Rename o.j.k.cli.klib.IdSignatureRenderer to avoid name clash with o.j.k.ir.util.IdSignatureRenderer
^KT-59486
2023-06-26 15:59:31 +00:00
Dmitriy Dolovov 4c0583e415 [IR] Two modes of signature rendering
^KT-59486
2023-06-26 15:59:31 +00:00
Alexander Udalov c66bc36382 Build: fix some warnings in buildSrc and build.gradle.kts 2023-06-26 15:42:21 +00:00
Artem Kobzar 89507c1b82 [K/JS] Remove dead branches for jsIsType 2023-06-26 14:00:09 +00:00
Sergej Jaskiewicz addb048ce9 [FIR] Generate signatures for synthesized class delegation fields
This is to align the behavior with K1.

^KT-57754 Fixed

Co-authored-by: Alexander Udalov <alexander.udalov@jetbrains.com>
2023-06-26 12:39:37 +00:00
Sergej Jaskiewicz 1ac3355a41 [FIR] Don't mangle FirFields as properties
The correct way to mangle a field is to just use its name.

This is a step towards fixing KT-57754. It will be fixed in
the next commit.
2023-06-26 12:39:37 +00:00
Sergej Jaskiewicz d73e44b89b [FIR] Set metadata for IrFields generated from FirFields
This is useful for signature tests (see how
IrMangledNameAndSignatureDumpHandler uses `metadata` to retrieve
the original FIR declaration)
2023-06-26 12:39:37 +00:00
Roman Golyshev a436f11caf [Analysis API] Add useful references to reference shortener APIs 2023-06-26 14:37:14 +02:00
Roman Golyshev b4c9a2616e KTIJ-25960 [Analysis API] Resolve static declarations in KDoc
^KTIJ-25960 Fixed
2023-06-26 12:27:26 +00:00
Sebastian Sellmair 4d91229d79 [Gradle] Implement KotlinDefaultHierarchyFallbackNativeTargetShortcutUsageDetected diagnostic
^KT-58676 Verification Pending
2023-06-26 11:36:18 +00:00
Sebastian Sellmair 8d6c4019c5 [Gradle] Implement KotlinMultiplatformSourceSetConventionsTest
^KT-58676 Verification Pending
2023-06-26 11:36:17 +00:00
Sebastian Sellmair c31c5ea0be [Gradle] Implement IosSourceSetConventionUsedWithoutIosTarget diagnostic
... in case when iosMain, iosTest conventions are used
w/o any ios target being applied

^KT-58676 Verification Pending
2023-06-26 11:36:17 +00:00
Sebastian Sellmair 6d1e039b77 [Gradle] Do not apply default hierarchy template for: test KT-47641...
See: KT-59596:
The test did not apply any hierarchy before as well, therefore this
change is returning the setup back to its original behaviour.

However, we therefore discovered an issue (tracked as KT-59596):
Compiling metadata compilations for cinterops is not desirable

^KT-58676 Verification Pending
2023-06-26 11:36:17 +00:00
Sebastian Sellmair 6f42446138 [Gradle][Minor] Improve documentation in KotlinHierarchyDsl
^KT-58676 Verification Pending
2023-06-26 11:36:17 +00:00
Sebastian Sellmair 37ec18d8d6 [Gradle][Minor] Fix typo in KotlinMultiplatformExtension documentation
^KT-58676 Verification Pending
2023-06-26 11:36:17 +00:00
Sebastian Sellmair f26f3e0738 [Gradle] Remove InternalKotlinHierarchyTemplate interface (in favor of using Impl directly)
^KT-58676 Verification Pending
2023-06-26 11:36:17 +00:00
Sebastian Sellmair 6d4dbfae28 [Gradle] Move KotlinHierarchyDsl documentation into KotlinHierarchyDsl.kt
^KT-58676 Verification Pending
2023-06-26 11:36:17 +00:00
Sebastian Sellmair a03fb02af3 [Gradle] Deduplicate documentation from KotlinHierarchyTemplate.Templates.default and applyDefaultHierarchyTemplate
^KT-58676 Verification Pending
2023-06-26 11:36:17 +00:00
Sebastian Sellmair 772bcb283d [Gradle] Replace KotlinSourceSetTree interface with simpler class
^KT-58676 Verification Pending
2023-06-26 11:36:17 +00:00
Sebastian Sellmair 85f4b72c8b [Gradle] Remove deprecation from deprecated KotlinTargetHierarchy entities
^KT-58676 Verification Pending
2023-06-26 11:36:17 +00:00
Sebastian Sellmair 18a2ceebea [Gradle] Keep deprecated KotlinTargetHierarchy in previous KotlinTargetHierarchy.kt source file
^KT-58676 Verification Pending
2023-06-26 11:36:17 +00:00
Sebastian Sellmair 1cd8089e92 [Gradle] Move KotlinHierarchyTemplate.Templates.default into -api module
^KT-58676 Verification Pending
2023-06-26 11:36:17 +00:00
Sebastian Sellmair 2a4f9b19f0 [Gradle] KotlinSourceSetConvention: KotlinSourceSet registration logic
Separate the retrieval and registration of KotlinSourceSets in the getValue function of KotlinSourceSetConvention. Add a custom Trace class to be stored in the isRegisteredByKotlinSourceSetConventionAt property for better readability and debugging purposes.
2023-06-26 11:36:17 +00:00
Sebastian Sellmair 0b57dac738 [Gradle] Deprecate native target shortcuts ...
... in favor of default hierarchy template

^KT-58676 Verification Pending
2023-06-26 11:36:17 +00:00
Sebastian Sellmair 845c8bd1c3 [Gradle] Implement KotlinGradlePluginDsl annotation and check in for binary compatibility validation
^KT-58676 Verification Pending
2023-06-26 11:36:17 +00:00
Sebastian Sellmair cec243ac3b [Gradle] apply KotlinHierarchyTemplate.default, by default
^KT-58676 Verification Pending
2023-06-26 11:36:17 +00:00