Commit Graph

14151 Commits

Author SHA1 Message Date
Ilya Gorbunov d8ee74222f [builtins-gen] Explicit visibility for companion objects and secondary constructors 2023-11-22 18:04:34 +00:00
Ilya Gorbunov ab7c2f2196 [stdlib] Explicit visibility and return types: builtins 2023-11-22 18:04:34 +00:00
Ilya Gorbunov df190b1265 [stdlib] Explicit visibility and return types: JVM internal 2023-11-22 18:04:34 +00:00
Ilya Gorbunov 2e030f213b [stdlib] Explicit visibility and return types: JVM 2023-11-22 18:04:34 +00:00
Nataliya.Valtman 6bbf5b83c8 Add compiler metrics to JPS build report
#KT-63549: Fixed
2023-11-22 11:30:08 +00:00
Alexander Korepanov 45c166abf8 [JS IR] Introduce special setMetadataFor*() for synthetic classes
^KT-63436 Fixed
2023-11-22 09:21:44 +00:00
Alexander Korepanov 9af681e234 [JS IR] Rename metadataUtils.kt -> metadataUtilsOld.kt 2023-11-22 09:21:44 +00:00
Alexander Udalov dec41e8c46 Improve muted K2 metadata (kotlinp) tests
Add comments referencing issues where K2 behavior is questionable, and
provide `.fir.txt` versions where behavior is different but fine.
2023-11-21 19:57:10 +00:00
Ilya Gorbunov 4d8cf4903c [stdlib] Explicit visibility and return types: DOM API 2023-11-21 18:14:09 +00:00
Ilya Gorbunov ce427b96b3 [stdlib] Suppress explicit api errors in DOM declarations generated by dukat
Suppressions should be removed once dukat supports generating
explicit public visibility and return types
2023-11-21 18:14:09 +00:00
Ilya Gorbunov cfa8a1dc0f [stdlib] Explicit visibility and return types: Wasm 2023-11-21 18:14:09 +00:00
Ilya Gorbunov 381a8fd55f [stdlib] Explicit visibility and return types: JS
Stepping test line number changes are due to changes in coroutineInternalJS.kt
2023-11-21 18:14:09 +00:00
Yahor Berdnikau ffa6bfc95e [Gradle] Partially restore top-level compiler options DSL in MPP
To support configuring free compiler arguments for all shared source
sets (KT-61573), we restore 'compilerOptions { }' DSL in the
multiplatform extension.

To avoid user confusion on accidentally using 'compilerOptions {}'
inside Kotlin targets and Kotlin compilations DSL, similar methods with
ERROR deprecation level were added into `KotlinTarget` and
`KotlinCompilation` interfaces. Invoking these interfaces will throw
UnsupportedOperationException. Such an approach works both for Kotlin
and Groove Gradle scripts.

^KT-63491 Fixed
2023-11-21 14:06:17 +00:00
Yahor Berdnikau 294b36e16f [Gradle] Repurpose 'kotlin.experimental.tryK2'
Now it sets +1 to default one language version. Property name was
updated to 'kotlin.experimental.tryNext'.

^KT-61975 Fixed
2023-11-21 11:58:45 +00:00
Yahor Berdnikau a20f21f76f [Gradle] Introduce 'kotlin.internal.compiler.arguments.log.level' property
This property allows changing log level for message printing the final
set of compiler arguments used to run compilation.

Possible levels are 'error', 'warning', 'info', 'debug'. Default level
is 'debug'.

^KT-60733 Fixed
2023-11-20 21:03:38 +00:00
Evgenii Mazhukin 5973951f71 [IC] Smoke tests for KMP IC, part 1
Assert reasonable compile avoidance when basic changes are made in a
multiplatform project

^Relates to KT-56963

Merge-request: KT-MR-13032
Merged-by: Evgenii Mazhukin <evgenii.mazhukin@jetbrains.com>
2023-11-20 17:17:27 +00:00
Dmitriy Dolovov 6de0b3a645 [Gradle][MPP] Minor: Don't use @GradleTestVersions in the test
^KT-62515
2023-11-20 13:40:54 +00:00
Ilya Goncharov 94ce4c06a7 [Gradle, Wasm] Use separate hierarchical methods for JS and wasi
^KT-63417 fixed
2023-11-20 10:30:58 +00:00
Ilya Goncharov dcab981ee8 [Gradle, Wasm] Use static source sets accessors for wasm
^KT-62955 fixed
2023-11-20 10:30:16 +00:00
Ilya Gorbunov 62700c3ec3 [stdlib] K/N ArrayList: restore constructor docs, correct modifier order 2023-11-20 02:24:40 +00:00
Ilya Gorbunov aa4419b7e3 [stdlib] Explicit visibility and return types: Collections 2023-11-20 02:24:40 +00:00
Ilya Gorbunov 0dd61c9f81 [stdlib] Explicit visibility and return types: Duration 2023-11-20 02:24:40 +00:00
Ilya Gorbunov da1d3be7f2 [stdlib] Explicit visibility and return types: StringBuilder 2023-11-20 02:24:40 +00:00
Ilya Gorbunov 92b3131c12 [stdlib] Explicit visibility and return types: HexFormat 2023-11-20 02:24:40 +00:00
Ilya Gorbunov 02e933b3ff [stdlib] Explicit visibility and return types: common 2023-11-20 02:24:39 +00:00
Artem Kobzar 1832f5a3f7 [K/JS] Introduce the ability to consume platform-specific cli arguments inside the main function ^KT-16981 Fixed 2023-11-18 11:01:34 +00:00
Ilya Gorbunov 66639d37ec [kotlin-test] Explicit public visibility and return types 2023-11-17 17:20:51 +00:00
Ilya Gorbunov 3a5276f4d3 [stdlib] Fix compilation warnings in js-ir-minimal 2023-11-17 17:19:05 +00:00
Leonid Startsev 477c668c80 Promote most deprecations in kotlinx-metadata-jvm to ERROR
because WARNING versions of them were already released at some point.

The following declarations were not promoted and have to be promoted later:

- KmProperty.hasGetter, .hasSetter
- Deprecations from readStrict/readLenient/write() rework

#KT-63157 In progress
2023-11-17 16:23:34 +00:00
Kirill Rakhman 4964ee12a9 [CLI] Update CLI argument descriptions after review 2023-11-17 14:36:28 +00:00
Dmitriy Dolovov bc8841c6fe [Gradle][MPP] Don't save library dependency versions in KLIB manifest
^KT-62515
2023-11-17 13:49:29 +00:00
Yahor Berdnikau 3413b07550 [IC, Gradle] Remove 'kotlin.incremental.useClasspathSnapshot' system property
^KT-62962 Fixed
2023-11-17 11:34:19 +00:00
Ilya Goncharov 342c9e8c81 [Gradle, JS] Set compiler arg ir and produce-* unconditionally
^KT-63312 fixed
2023-11-17 10:25:21 +00:00
Anton Lakotka 980708e533 [Gradle] Check if host-specific metadata artifact exists for GMT
In gradle metadata transformations for CInterops in composite builds
it is possible that resolved artifact is not actually created.
For example if host machine is not MacOS but composite build has
projects with enabled Apple targets. So apple-specific tasks will be
disabled but still configured and during dependency resolution
its outputs will be provided in artifact view.

We have already checked for cases when there is no resolved artifact.
But apparently it is not enough, and it is important to check that file
exists physically.

^KT-63197 Verification Pending
2023-11-17 08:00:40 +00:00
Anton Lakotka 9fc7d3693e [Gradle] Test composite build import with enabled CInterop commonization
On non-mac machines. With projects that have enabled MacOS targets.

In this scenario we don't want to ruin IDE UX for users that just
want to use IDE and work with project parts that is not related to apple

^KT-63197
2023-11-17 08:00:40 +00:00
Alexander Shabalin 9ad7b00613 [K/N] Migrate some runtime/workers tests to new testing infra ^KT-61259 2023-11-17 07:42:28 +00:00
Artem Kobzar ff50d40b32 [K/JS] Rework kotlin tests compilation to make it works with per-file granularity ^KT-61525 Fixed 2023-11-16 19:02:04 +00:00
Alexander.Likhachev 6fbd26905a [Gradle] Add Gradle 8.2+ plugin variant
Fixups KT-52976 as the intention was to remove conventions registration. However until this commit, `gradle81` variant was used for all the 8.1+ versions providing an implementation that registers conventions.
^KT-63499 Fixed
2023-11-16 16:59:02 +00:00
Alexander.Likhachev 965b6b544d [Gradle] Add integration test for KT-63499 2023-11-16 16:59:02 +00:00
Ilya Chernikov 6877fa8e42 Scripting: remove obsolete script-util module
#KT-58367 fixed
2023-11-16 15:46:08 +00:00
Nataliya.Valtman c332e1beb5 Remove BuildStatsService.applyIfInitialized outside BuildFlowService
#KT-58768 In Progress
2023-11-16 15:22:01 +00:00
Yahor Berdnikau 55f6614b66 [Gradle] Increase max Kotlin daemon heap size to 2g for all kapt tests
Apparently, they all require more than 1g of heap size to run kapt.
2023-11-16 08:01:33 +00:00
Alexander.Likhachev 11e0edc124 [Gradle, K/N] Remove the enableEndorsedLibs flag
This is the last stage of the flag's deprecation cycle.
^KT-56455 Fixed
2023-11-15 17:01:40 +00:00
Yahor Berdnikau 580c2a490d [Gradle] Apply attribute disambiguation rules conditionally
Not all Kotlin disambiguation rules are required for non-MPP projects.
On the other hand, they lead to increased memory consumption in Gradle
daemon especially notable on big multimodule projects.

To address this memory increase, we start to apply these rules
conditionally based on the applied plugin.

^KT-63005 Fixed
2023-11-15 11:18:41 +00:00
Yahor Berdnikau 6eca282e9a [Gradle] Bump minimal supported AGP version to 7.1.3
^KT-62939 Fixed
2023-11-15 10:31:03 +00:00
Yahor Berdnikau 59f544cb7c [Gradle, Kapt] Don't immediately check if kaptClasspath dependencies are empty
Now sub-plugins are applied to compilation before users `afterEvaluate`
closure execution, which could lead to unexpected by the user state.
For example, when a user adds dependencies to 'kaptClasspath' in
'afterEvaluate'.

This fix removes check in Kapt plugin if dependencies are present on
'kaptClasspath' and moves it into KaptTask.onlyIf spec. So the task
will still have SKIPPED state if there are no AP provided.

^KT-63366 Fixed
2023-11-15 08:42:28 +00:00
Anton Lakotka 951830fcef [Gradle] Use source set name for Cinterop configurations
This will ensure that source set have isolated Cinterop configurations.
With proper extendsFrom relations.
And prevent from dependencies i.e. from linuxMain to nativeMain if they
both have the same set of underlying targets.

^KT-63338 Verification Pending
2023-11-14 22:26:27 +00:00
Anton Lakotka 645d263474 [Gradle] Test that source set have own Cinterop configurations
It is necessary to prevent leaking dependencies in source set hierarchy
i.e. if linuxMain depends on some project with cinterops and
nativeMain also have the same set of underlying targets it is important
that nativeMain should not see any dependencies from linuxMain!

And vice versa, if linuxMain should see own + parents dependencies.

^KT-63338
2023-11-14 22:26:26 +00:00
Yahor Berdnikau 656b61b945 [Gradle] Restore writing errors into <project_dir>/.gradle directory
This is required for compatibility with older IDEA releases where it
expects errors only in <project_dir>/.gradle/kotlin/errors directory.

It is possible to disable such behaviour via
"kotlin.project.persistent.dir.gradle.disableWrite" property.

^KT-58223 Fixed
2023-11-14 18:38:12 +00:00
Yahor Berdnikau 070de9cc85 [Gradle] Split global and project persistent caches
Now for project persistent caches plugin will use '<rootDir>/.kotlin'
directory. Global persistent cache has stayed in the
'<user.home>/.kotlin' directory.

^KT-58223 Fixed
2023-11-14 18:38:12 +00:00