Commit Graph

1276 Commits

Author SHA1 Message Date
Roman Golyshev
b4c0cd8609 KTIJ-33722 [kotlin] Add missing kotlin.code-insight.fixes.k2 dependency to kotlin.compiler-plugins.assignment.common.k2 module
Without this dependency, using `ImportQuickFixProvider` class leads
to "must not be requested from main classloader" errors

^KTIJ-33722 Fixed


(cherry picked from commit e5104e117aefdeaad69175c4bced459fd6a47907)

IJ-CR-159651

GitOrigin-RevId: cd0dc21c96ea05b3ade32e41b18f6949b923c7d6
2025-04-08 19:39:18 +00:00
Roman Golyshev
a1f2ccbf8f [kotlin] Refactor ImportQuickFixProvider and ImportQuickFixFactories
Reuse `ImportQuickFixProvider` as a factory for the more specific factories
in `ImportQuickFixFactories`

Related issues:
KTIJ-29655
KTIJ-32771
KTIJ-32739
KTIJ-32143

(cherry picked from commit 547bb0a9e374d114b1bbb6d616ccf87f42d6554f)

IJ-CR-158539

GitOrigin-RevId: ff005eefa896924523bc8fffab1f7796e8223679
2025-03-31 19:48:38 +00:00
Vladimir Krivosheev
2744060f54 IJ-CR-146078 add support for whenGuards, set 17 as default jvm target for custom kotlinc opts
GitOrigin-RevId: 9b107d08ff3b588c3c5099a95276ac714ac6ea19
2025-02-17 12:06:29 +00:00
Vladimir Krivosheev
a59247fe0f update bazel files
GitOrigin-RevId: 9c0599fc72c5eefddedd21b65242c39f1f6748fa
2025-02-14 21:08:26 +00:00
Stanislav Ruban
59ffc34acf [migration to Kotlin LV 2.2] Update JPS modules w/ Kotlin w.r.t. KTLC-3
GitOrigin-RevId: d6fccd2ac258a15d122402e2fb1ea6db070703a5
2025-02-13 20:31:15 +00:00
Roman Golyshev
f59df1df2a KTIJ-32842 [kotlin] Do not pass operation token for FirAssignmentPluginQuickFixRegistrar
This particular place does not matter, because the
corresponding test is still disabled, see KTIJ-25396.

This will be probably fixed at the same time with
other operators (see KTIJ-31353).

GitOrigin-RevId: 50402204f1b88c78adad0fd3641f3108492db7a0
2025-02-06 18:46:22 +00:00
Vladimir Krivosheev
c3c21baac5 update bazel files
GitOrigin-RevId: 1a10e8174a47f688a95a93af0540f722462acd97
2025-02-03 11:42:18 +00:00
Daniil Ovchinnikov
dea8eddb0c rename intellij.platform.editor -> intellij.platform.editor.ui
GitOrigin-RevId: f4aa008b77368945ce9651fdc47f9463e3445347
2025-02-02 16:22:43 +00:00
Anna Kozlova
c608312e5e [kotlin] parcelize tests: configure in EDT
otherwise, tests fail and leak project

// LastInSuite.testProjectLeak

GitOrigin-RevId: 6e59d56e87af2f28540e3ba685290b93233448f7
2025-01-28 19:16:55 +00:00
Leonid Shalupov
879280e32e kotlin: cleanup: remove unused imports
GitOrigin-RevId: c448282cf97771902407da6abaeff538a24b825a
2025-01-27 20:42:04 +00:00
Roman Golyshev
0fd9ed440c KTIJ-32821 [kotlin] Restore actual diagnostics instead of relying on KotlinUnresolvedReferenceKind
^KTIJ-32821 Fixed

GitOrigin-RevId: b388fb7c719c90ed8c8491029ed54e9d7b663163
2025-01-22 20:27:03 +00:00
Ilya.Kazakevich
55fdccf9d9 Regenerate Kotlin tests to update copyright year.
I had to do that to make `AllTestsGeneratedTest` pass and accept my changes. Happy new year.

GitOrigin-RevId: aacd330b8662057c33b01954cdffbfa2954cd10c
2025-01-01 03:15:06 +00:00
Vladimir Krivosheev
0bc1cf1557 update bazel files
GitOrigin-RevId: 7320d3eff3aba093692ce66839c720ece6d7c4db
2024-12-30 11:28:24 +00:00
Vladimir Krivosheev
7b9ec58009 do not export intellij.database.connectivity.tests
GitOrigin-RevId: a1ef44dfa34cde110c9e6cad19d11b5e3019ab72
2024-12-28 21:45:55 +00:00
Vladimir Krivosheev
5649dd91d4 do not export kotlin.test-framework
GitOrigin-RevId: 1e1817357a7da35e9c5f43dca480e412b6be528c
2024-12-28 01:15:41 +00:00
Vladimir Krivosheev
8a5e345e43 don't export kotlin.tests-common
GitOrigin-RevId: 020dec6f2790a34e685e47487b83e4e72dc8d31e
2024-12-27 21:09:06 +00:00
Vladimir Krivosheev
2c56b99fd5 do not export intellij.platform.testFramework
GitOrigin-RevId: 4c2c86b3ba376268aba04487e363685656fea2e3
2024-12-26 22:08:08 +00:00
Vladimir Krivosheev
2b781b159a do not export deps blindly (part 5)
GitOrigin-RevId: 27b64867fac677b6b8a07ca82c6ab3cf7044db1e
2024-12-24 11:44:44 +00:00
Vladimir Krivosheev
a522f96d66 do not export deps blindly (part 3)
GitOrigin-RevId: 7277ece9ded25f1111febc8dccaba9ac8cc75c21
2024-12-22 20:28:42 +00:00
Vladimir Krivosheev
98799639aa do not use _test as lib - test targets do not support this
GitOrigin-RevId: f2f49db4294b6a64040dbbd5f1d95e972cbd70a3
2024-12-15 18:32:30 +00:00
Nikolay Chashnikov
6a8e578f0c [intellij project configuration] add missing '-Xjvm-default=all' parameter in Kotlin compiler arguments
All modules in intellij project use should use this parameter to ensure that newly added interface methods with default implementation will have it in bytecode to avoid breaking compatibility.

We have a test which verifies that, but it was disabled some time ago by a mistake. This change is also needed to re-enable it.

GitOrigin-RevId: 8fec5d419bf8da2b1fa7058d61ef04a3e8ebc6fa
2024-12-13 19:12:35 +00:00
Mikhail Filippov
eaea18cc07 KT-73477 Workaround for OptIn Kotlin issue
GitOrigin-RevId: af871a767bc1e25d9b37c4db6f10de107cd1f8f7
2024-11-28 17:43:52 +00:00
Vladimir Krivosheev
e5dc4387fb cleanup
GitOrigin-RevId: 623a925aa1314a17da21db70df48855a9869c493
2024-11-27 13:53:42 +00:00
Vladimir Krivosheev
17916c90f8 libraries -> lib, resources, opt-in, test deps
GitOrigin-RevId: db66ee95dcb0f0553b40c9cc56cd6afed8634cdd
2024-11-27 13:53:42 +00:00
Ilya Kirillov
3adb6552e9 [Kotlin] mark IdeaModuleInfo and related API with @K1ModeProjectStructureApi
- For K1 parts, it's OK to use it API
- K2 and shared parts should be migrated to `KaModule` API

KTIJ-31422

GitOrigin-RevId: fc6d9dd6b259859aaf93f206674a0b0e2c487fc9
2024-10-23 14:57:09 +00:00
Patronus
364a0f319e Merge refs/patronus/safepush/0b43752d45fa443abaccaf4684092b1c into master
GitOrigin-RevId: 17e27c71f723426efd491aa98076da18e0d6d901
2024-10-21 21:15:26 +00:00
Ilya Kirillov
900a0c287e [kotlin] implement a helper API to get KaModule by PsiElement
for easier discoverability

KTIJ-31422

GitOrigin-RevId: 8333268bd3b9844ab190aa199def4d515b967110
2024-10-21 19:38:17 +00:00
Sergej Jaskiewicz
39febde772 [JS] Drop support for JS legacy backend in kotlinx-serialization compiler plugin
KT-70223

GitOrigin-RevId: e7b4ae8631b258132aa5a65dc3788ca970bbad59
2024-10-21 17:32:19 +02:00
Alexander Udalov
c251b6961f [kotlin] Minor, move noarg descriptor utils to IDE plugin sources
In the main Kotlin repo, they were only used from the old JVM backend
implementation of noarg, which is being removed right now.

 #KT-71197

GitOrigin-RevId: 4faae27bfc6c5e8aec5c10c7e7bb3a09825ad351
2024-10-07 23:59:45 +00:00
Alexander Udalov
9cbd851ab4 [kotlin] Remove old JVM backend extensions
#KT-71197

GitOrigin-RevId: 04ed6c319927657d919a1574968d2691be22e7b4
2024-09-25 00:31:09 +02:00
Mikhail Filippov
f13d92e82f IJPL-150165 switch to invoke dynamic lambdas in Kotlin
GitOrigin-RevId: 63ba45a21874cc723917982996fce1a510b2a182
2024-09-05 11:19:31 +00:00
Mikhail Filippov
bf43f2fc01 IJPL-150165 bump Kotlin language and API version
GitOrigin-RevId: a59dc8ca214a5047773fccf1cf28a1e1b07acf68
2024-08-30 22:15:55 +00:00
Aleksei.Cherepanov
a1c8f7e38a KTIJ-30901 Optimize modifying of compiler arguments with the compiler arguments plugin options and classpath
Previously we did overwrite compiler arguments each time, which triggered expensive serialization of compiler arguments. Now we serialize only if necessary

^KTIJ-30901 Fixed

GitOrigin-RevId: 5c269b19d9c6791631468d8dca2beac3cbbb4e87
2024-08-07 13:02:55 +00:00
Andrey Cherkasov
5d551b49b4 [kotlinx-serialization] Provide a quick fix for the [JSON_FORMAT_REDUNDANT] warning.
The quick fix extracts Json format creation to property.

IJ-MR-140263
^KTIJ-30282

GitOrigin-RevId: eb1367b5009275272722d32a3aff34d1774d3d2a
2024-08-01 20:48:25 +00:00
Andrey Cherkasov
88b32923c0 [kotlinx-serialization] Fix the [USELESS_CAST] warning
IJ-MR-140263
^KTIJ-30282

GitOrigin-RevId: b8f6e01eb9f4242bcc02417aae8d1ba61dc3c3ac
2024-08-01 20:48:25 +00:00
Andrey Cherkasov
f86372c4d4 [kotlinx-serialization] Rename
IJ-MR-140263
^KTIJ-30282

GitOrigin-RevId: e9a3546885e443abaf54634d8ea1e76deb8ec40b
2024-08-01 20:48:25 +00:00
Andrey Cherkasov
3fa68be656 [kotlinx-serialization] Enhance AddKotlinxSerializationTransientImportQuickFix for K2
The quick fix previously only suggested importing `kotlinx.serialization.Transient`. However, the [INCORRECT_TRANSIENT] warning can appear even when `kotlinx.serialization.Transient` is already imported. This enhancement allows the quick fix to handle such cases as well.

^KTIJ-30282

GitOrigin-RevId: 244acbe9ed929f0eeef8f4789a28ef82e4cc3dbb
2024-08-01 20:48:25 +00:00
Andrey Cherkasov
7e352fea12 [kotlinx-serialization] Make class internal
IJ-MR-140263
^KTIJ-30282

GitOrigin-RevId: 264424a1edee5acfc9f2f54a7c49f7fa61bfe92b
2024-08-01 20:48:25 +00:00
Andrey Cherkasov
d7e4b7ad15 [kotlinx-serialization] Port AddKotlinxSerializationTransientImportQuickFix for K2
This quick fix is for the [INCORRECT_TRANSIENT] compiler warning.

^KTIJ-30282

GitOrigin-RevId: bdc0215af7295c7b3b845acc22cda8b1eda35aa3
2024-08-01 20:48:25 +00:00
Andrey Cherkasov
192d98bfaf [kotlinx-serialization] Port JsonRedundantDefaultQuickFix for K2
This quick fix is for the [JSON_FORMAT_REDUNDANT_DEFAULT] compiler warning.

^KTIJ-30282

GitOrigin-RevId: 02387ba431ceb3fdfd924a26a7402bc3c3a8aab4
2024-08-01 20:48:25 +00:00
Andrey Cherkasov
5ca2c935e1 [kotlinx-serialization] Add new module for quick fixes for K2
^KTIJ-30282

GitOrigin-RevId: 55afae1942c93511bb937695398300700fe5e50b
2024-08-01 20:48:25 +00:00
aleksandrina-streltsova
291300190d [kotlin] k2 Import Fix: refactor
extract creation of import fixes into a dedicated object to better distinguish between the collection of import candidates + creation of fixes and the implementation of import fix
KTIJ-29655

GitOrigin-RevId: 4e72e233f4a66f86332d1658c96238010c5bb9b5
2024-07-29 10:03:20 +00:00
Yan Zhulanow
f0132d1fa6 [kotlin] Clean up type relation checker deprecations in Analysis API usages
^KT-68884

GitOrigin-RevId: 7a7a7b50f52df86eeac313c3718bcb7013862938
2024-07-12 07:39:22 +00:00
Yan Zhulanow
4c26a5ff2e [kotlin] Clean up symbol provider deprecations in Analysis API usages
^KT-68884

GitOrigin-RevId: 88ae06a8e485d6a40f99fe6511175426e766a26b
2024-07-12 07:39:21 +00:00
Yan Zhulanow
23bd2ea087 [kotlin] Migrate 'analysisSession' to 'useSiteSession'
^KT-67996

GitOrigin-RevId: 4bbcd499ea9e7ddedab2fc1229bbe4bd811e8c04
2024-07-12 07:39:21 +00:00
Yan Zhulanow
0e04c18f01 [kotlin] Get rid of deprecations in annotation-related Analysis API usages
^KT-67996
^KT-68884

GitOrigin-RevId: b19c56ec4bc9abde55d3b6ef76c0cf2c3e42b84e
2024-07-12 07:39:21 +00:00
Yan Zhulanow
5bc4eeb297 Merge commit '8fb6929b0182cb3275422a292e7a700a98862c9b'
GitOrigin-RevId: cc4590bffe453a482df6f8f23da4aeeaa79ba363
2024-06-24 18:51:50 +09:00
Yan Zhulanow
effc441609 [kotlin] Migrate 'getKtType()' to 'type'
^KT-67996

GitOrigin-RevId: 9aa091b446003acdd256d0a1a244b6eb582854a5
2024-06-23 20:30:36 +00:00
Yan Zhulanow
eb618328f1 [kotlin] Migrate 'KtStarTypeProjection' to 'KaStarTypeProjection'
^KT-67996

GitOrigin-RevId: 5131d21964508594399fd2420e9aca10483f3bd6
2024-06-23 20:30:35 +00:00
Yan Zhulanow
2e7eb91e72 [kotlin] Migrate 'KtType' to 'KaType'
^KT-67996

GitOrigin-RevId: d079b3ca7817c537905abc2336e1a584533ca25d
2024-06-23 20:30:35 +00:00