Commit Graph

102611 Commits

Author SHA1 Message Date
Artem Daugel-Dauge e093852ebb [Gradle] Fix test data after KT-58316 2023-07-12 13:04:39 +00:00
Yahor Berdnikau 73f6316f27 [repo] Enable warnings as errors for Gradle Kotlin scripts 2023-07-12 12:49:32 +00:00
Yahor Berdnikau ed8fc64257 [repo] Update to Gradle 8.2.1 version
This Gradle release also fixes 2 security vulnerabilities:
https://docs.gradle.org/8.2.1/release-notes.html
2023-07-12 12:49:32 +00:00
Dmitrii Krasnov f2816a5531 Added property for overriding konan distribution location
#KT-50463 Fixed

Merge-request: KT-MR-10310
Merged-by: Dmitrii Krasnov <Dmitrii.Krasnov@jetbrains.com>
2023-07-12 12:36:51 +00:00
Anton Lakotka 2f7f69ed4f [Gradle] Remove requiresVisibilityOf API and related checks
^KT-58228 Verification Pending
2023-07-12 11:59:27 +00:00
Brian Norman 10ed26991d [FIR] Extract LHS receiver of assignment operator statements
#KT-53490 Fixed
2023-07-12 11:41:33 +00:00
Sebastian Sellmair 14276642d4 [Gradle] Deprecate ios target shortcut
Which was forgotten in 0b57dac738

^KT-58676 Verification Pending
2023-07-12 10:51:01 +00:00
Timofey Solonin c245fa45e3 Split K2 and K1 test data for multiplatform feature diagnostic
and add an explicit expect to the test data

^KT-31281
2023-07-12 10:50:33 +00:00
Sebastian Sellmair 0880b4cb34 [Gradle] KotlinTargetsDsl: Remove undesirable AnnotationRetention.SOURCE
KTIJ-26247
2023-07-12 10:50:11 +00:00
Alexander.Likhachev 009cda5062 [Gradle] Adjust the MPP test project for KT-34901
Following the resolution of KT-59595, the java plugin is no longer applied in MPP projects. However, the `java-test-fixtures` plugin is currently non-functional due to its reliance on the `java` plugin (https://github.com/gradle/gradle/blob/e95eafb8c43c5cd404bd235fa0a69c58cab6f5d6/subprojects/plugins/src/main/java/org/gradle/api/plugins/JavaTestFixturesPlugin.java#L60).
2023-07-12 10:20:15 +00:00
Anton Lakotka a55b74d4e0 [Gradle] Elevate DeprecatedJvmWithJavaPresetDiagnostic to error
^KT-59320 Verification Pending
2023-07-12 10:19:39 +00:00
Anton Lakotka cd5e4611eb [Gradle] Elevate CommonMainWithDependsOnDiagnostic to error
^KT-59311 Verification Pending
2023-07-12 10:19:38 +00:00
Anastasia.Nekrasova fcba0ad75e [Test] Add a test covering for resolution to subsumed members for raw types
^KT-57620
2023-07-12 09:11:01 +00:00
Timofey Solonin e12e78d96b Add an explicit diagnostic for when expect/actual modifiers are used in
an unsupported compilation

^KT-31281
2023-07-12 08:29:28 +00:00
Nikolay Krasko cab0487f98 Fix implicit dependency validation for zipCompilerSign
Checksum tasks uses the directory output, but the directory is not
empty, compiler.zip is among files in target directory. And this is
probably the reason why gradle now claims zipCompilerChecksum should be
added as direct dependency (see the error message below).

Workaround: generate checksum in separate directory and copy the
resulting file to directory with the compiler.zip. Note that `Copy` task
can't be used because it also declares target directory as an output.

Reproduce:

```
gradle zipCompilerWithSignature -Psigning.gnupg.keyName=???????? -Psigning.gnupg.passphrase=test -PsigningRequired=true -Pteamcity=true
```

Error:

```
org.gradle.internal.execution.WorkValidationException: A problem was found with the configuration of task ':zipCompilerSign' (type 'Sign').
    - Gradle detected a problem with the following location: '/mnt/agent/work/***/kotlin_CompilerArtifacts/dist/kotlin-compiler-1.9.20-dev-6119.zip'.

      Reason: Task ':zipCompilerSign' uses this output of task ':zipCompilerChecksum' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed.

      Possible solutions:
        1. Declare task ':zipCompilerChecksum' as an input of ':zipCompilerSign'.
        2. Declare an explicit dependency on ':zipCompilerChecksum' from ':zipCompilerSign' using Task#dependsOn.
        3. Declare an explicit dependency on ':zipCompilerChecksum' from ':zipCompilerSign' using Task#mustRunAfter.

      Please refer to https://docs.gradle.org/8.1.1/userguide/validation_problems.html#implicit_dependency for more details about this problem.
```

KTI-1285
2023-07-12 07:37:28 +00:00
Abduqodiri Qurbonzoda 7346cf4777 Introduce jdk-api-validator to ensure kotlin-reflect uses jdk6 API
Merge-request: KT-MR-6930
Merged-by: Abduqodiri Qurbonzoda <abduqodiri.qurbonzoda@jetbrains.com>
2023-07-12 05:13:08 +00:00
Leonid Startsev 5424c54fae Make changelog and migration guide for kotlinx-metadata-jvm:0.7.0 2023-07-11 15:56:07 +00:00
Artem Kobzar fdda394a77 [K/JS] Calculate generated function names based on signatures of argument types (instead of fqNames) ^KT-49077 Fixed 2023-07-11 13:14:45 +00:00
Denis.Zharkov e94a0b8483 K2: Suppress "unused" for some methods at DependencyListForCliModule
Because we assume this part as a part of a public API
2023-07-11 13:12:22 +00:00
Denis.Zharkov e98890cece K2: Remove a bunch of unused declarations 2023-07-11 13:12:22 +00:00
Denis.Zharkov 1705d5f704 K2: Add @Supress("unused") to debug-related helpers 2023-07-11 13:12:22 +00:00
Denis.Zharkov f7e54fa76a K2: Simplify FirToConstantValueTransformer hierarchy
FirToConstantValueTransformerSafe was unused and then
there only one FirToConstantValueTransformer left
2023-07-11 13:12:22 +00:00
Denis.Zharkov 379ec2fae8 K2: Get rid of redundant enum at FirOptInUsageBaseChecker 2023-07-11 13:12:22 +00:00
Denis.Zharkov 987fa87c90 K2: Remove redundant parameters in ClassWrapper 2023-07-11 13:12:22 +00:00
Denis.Zharkov 03e06be324 K2: Remove redundant TypeModifier class 2023-07-11 13:12:22 +00:00
Dmitriy Dolovov b7bd078a31 [PL] Lower the default PL engine messages log level down to INFO
^KT-59136
2023-07-11 11:37:35 +00:00
Leonid Startsev 98cfa0315e Use 'number' instead of 'amount' because 'times' is a countable noun. (#5145) 2023-07-11 13:21:15 +02:00
Abduqodiri Qurbonzoda f152fa537d Collection.toString() should not throw if it contains itself
Merge-request: KT-MR-10591
Merged-by: Abduqodiri Qurbonzoda <abduqodiri.qurbonzoda@jetbrains.com>
2023-07-11 09:58:38 +00:00
Jinseong Jeon 6fc02c3408 SLC: ROOT package exists no matter what
^KT-59843 Fixed
2023-07-11 11:47:23 +02:00
Ivan Kylchik 076305bb78 [Test] Drop SMAPTestUtil.kt file
It is not used anywhere. Probably left after transition to new test
infrastructure.
2023-07-11 09:30:26 +00:00
Bogdan Mukvich 418404b597 Support NOASSERTION value for downloadUrl in SBOM
Fixes compatibility with Gradle 8.2

^KTI-1289
2023-07-11 09:12:37 +00:00
Mikhail Glukhikh 39406710b2 FIR2IR: fix origin calculation for explicit inc/dec calls 2023-07-11 08:28:04 +00:00
Mikhail Glukhikh f8ca440e96 K2: resolve Java enum entries from the beginning (related to KT-59464) 2023-07-11 08:28:04 +00:00
Mikhail Glukhikh e6d43c1f48 FIR2IR: simplify operations with getStatementsOrigin
#KT-54989 Fixed
2023-07-11 08:28:04 +00:00
Mikhail Glukhikh ba0ab38b83 K2: set vararg type for Java annotations #KT-59464 Fixed 2023-07-11 08:28:04 +00:00
Mikhail Glukhikh 6f8e2b4718 FIR2IR: Drop a set of redundant or unclear TODOs 2023-07-11 08:28:04 +00:00
Mikhail Glukhikh c2135b72c4 Fir2IrLazyProperty: simplify backing field check a little bit 2023-07-11 08:28:04 +00:00
Mikhail Glukhikh 71456c5514 FIR2IR: properly set constant expression type 2023-07-11 08:28:04 +00:00
Mikhail Glukhikh 09175c7d56 Fir2IrLazyProperty: drop redundant error type check 2023-07-11 08:28:04 +00:00
Mikhail Glukhikh 0e6a7bbe82 FIR2IR: simplify ConversionTypeOrigin/Context 2023-07-11 08:28:04 +00:00
Mikhail Glukhikh 2c0c9e5b5c FIR2IR: drop error type check in createIrProperty 2023-07-11 08:28:04 +00:00
Mikhail Glukhikh 595aace885 Fir2IrConverter: unite two process*Members functions in processClassMembers 2023-07-11 08:28:04 +00:00
Artem Daugel-Dauge 2e5ae122ea [Gradle] Forbid manual pod install invocation when Kotlin framework is not yet built
^KT-59263 Verification Pending
2023-07-10 18:28:59 +00:00
Alexander.Likhachev 8ae0f61028 [Gradle] Associate the textFixtures source set with main and test ones
#KT-34901 Fixed
2023-07-10 18:23:20 +00:00
Alexander.Likhachev fcb7010726 [Gradle] Add integration tests for KT-34901 2023-07-10 18:23:20 +00:00
Timofey Solonin 792b6482c0 Emit MultiPlatformProjects diagnostic on all declarations
where expect/actual modifier is present

^KT-31281
2023-07-10 17:26:23 +00:00
Sergej Jaskiewicz 341f61428b [klib] Restore compatibility for IdSignature.CommonSignature constructor
^KT-59771 Fixed
2023-07-10 16:27:47 +00:00
Svyatoslav Scherbina 710381e489 Native: don't report Objective-C-related errors on expect classes
An expect class might lack some details and thus seem incorrect to the
compiler, while the corresponding actual class is totally fine.
Due to the specifics of the compiler, this happens more often then it
should (because the compiler actually always analyzes expects along
with actuals, with most references actualized).

For example, in KT-52882 the compiler analyzes an expect class
(TestImpl), but the class refers to the actual interface Test as its
supertype, meaning that the compiler sees TestImpl as a class inheriting
an Objective-C protocol but not an Objective-C class, which is
prohibited. While the actual class has its super types in order.

So, in reality, from both actualized and non-actualized points of view,
the code is totally correct, and the error was reported only because of
the way the compiler handles multiplatform.

Those compiler checks only matter for the actual class anyway, so
disabling them for expect classes is harmless.

^KT-52882 Fixed
2023-07-10 16:15:49 +00:00
Alexander Shabalin 6619edbbac [K/N] Fix redundant sp removal tests 2023-07-10 15:45:30 +00:00
cristiangarcia 0946039661 Reduce number of tasks realized eagerly from Konan Plugin 2023-07-10 14:42:30 +00:00