Commit Graph

1099 Commits

Author SHA1 Message Date
Ilya Chernikov 09ea4116e4 Implement forced script configuration reloading API for plugins
#KT-43288 fixed
2021-02-09 20:33:18 +00:00
Igor Yakovlev 5d4606daaa [FIR IDE] Remove LightClassProvider 2021-02-01 21:21:02 +03:00
Vladimir Dolzhenko 913c298be8 Kotlin highlight passes are reworked
#KT-37702 Fixed
2021-02-01 13:18:38 +00:00
Pavel Kirpichenkov c0dd731818 Load JVM built-ins in IDE from module dependencies
Fix built-ins for JVM platform and make them consistent
with module's dependency on standard library. Changes
don't affect non-JVM platforms.

Previously all built-ins in IDE were loaded from classloader
and were based on the same pre-serialized .kotlin_builtins files.
This approach is generally not correct as built-in declarations
differ for different platforms, but it had been working for a while
without immediately observalble effects (see KT-33233 for more info).
After changes in standard library JvmBuiltins started producing
false errors (see KT-39728).

To fix this, JVM built-ins in IDE now utilize the same technique as
applied in CLI: using dependency on standard library as a module
for built-ins instead of artificial module that considers only
.kotlin_builtins.

Change summary:
- Provide JvmBuiltins with kind FROM_DEPENDENCIES
  for all modules with stdlib dependency in IDE
- Add JvmBuiltinsPackageFragmentProvider to JVM-ish module resolvers
  (JVM and Composite with JVM platform) to support their use as
  built-ins module
- Create KotlinBuiltInsMetadataIndex file index for tracking libraries
  containing .kotlin_builtins to support JvmBuiltinsPackageFragmentProvider
- Create KotlinStdlibIndex file index for tracking kotlin-stdlib(-common),
  which looks for "Kotlin-Runtime-Component" manifest attribute
- Add caching service to track LibraryInfo for kotlin-stdlib(-common)
- Put LibraryInfo for kotlin-stdlib(-common) alongside SDKs
  due to the need to resolve that modules in BuiltInsCache
- Update BuiltInsCache to separate JvmBuiltins by module's dependency
  on stdlib and JDK
- Make platform of KotlinSDK common instead of JVM
- Set built-ins module lazily in IDE

^KT-33233 Verification Pending
2021-01-14 17:28:15 +03:00
Andrei Klunnyi f8cca288ab KT-44075 Sealed interfaces: New Kotlin Class/File menu update
^KT-44075 Fixed
2020-12-24 13:07:52 +00:00
Ilya Kirillov d06a5fb413 FIR IDE: disable some script stuff in FIR plugin as causes exceptions 2020-12-23 17:16:23 +01:00
Ilya Kirillov a2befd4635 FIR IDE: add missing ClsJavaStubByVirtualFileCache service 2020-12-23 17:16:00 +01:00
Andrei Klunnyi 3e8016ed25 KTIJ-717 [Java side inspection]: "implementation of Kotlin sealed" 2020-12-21 11:44:16 +01:00
Andrei Klunnyi 4817d5e01d KTIJ-585 [Gradle Runner]: main() cannot be launched from AS 4.1
Android gradle-project model differs from what we have for pure Java
and MPP. It's the reason why application classpath cannot be collected
correctly.
Until universal solution is provided delegation to gradle is put under
the registry flag. If disable platform runner is used as before.
2020-11-30 15:44:37 +00:00
Dmitriy Novozhilov 986ab9cb54 Build: remove useless .as40 files 2020-11-28 14:25:54 +03:00
Yan Zhulanow 5f7d7ff9c7 Parcelize: Activate checkers only when the plugin is enabled for module (KT-43291) 2020-11-12 05:38:27 +09:00
Vyacheslav Gerasimov 8620d26a8a Delete 193 bunch files 2020-11-11 14:28:53 +03:00
Sam Wang d1ba2f3d46 Restore KotlinExplicitMovementProvider in as41 and as42 2020-11-11 11:37:27 +01:00
Vladimir Dolzhenko 4f76c747ec Mark org.jetbrains.kotlin.mavenProjectImportHandler as dynamic 2020-11-11 10:29:16 +00:00
Vladimir Dolzhenko 51a1990e50 Drop missing gradle extensions from jvm-common.xml
Similar to 0cad41bb0c

Relates to ^KT-38518
2020-11-11 10:29:15 +00:00
Ilya Kirillov 5fae769a90 Wizard: use new compose icon
#KT-43033
2020-10-31 16:57:07 +03:00
Andrei Klunnyi 55048f40ab Disable "Incomplete destructuring declaration"
^KT-43037 fixed
2020-10-30 09:33:18 +01:00
Yan Zhulanow 9faf91f55d Fix Parcelize settings serialization (KT-42958) 2020-10-28 00:43:20 +09:00
Leonid Startsev 8d999a2c13 Disable kx.ser plugin inside descriptors serialization in the IDE
Since IDE does not perform any serialization of descriptors, and
metadata written to the 'serializationDescriptorSerializer'
deleted only on call to DescriptorSerializer,
enabling this extension in the IDE effectively causes memory leaks.

 #KT-39624 Fixed

Pass SerializationDescriptorSerializerPlugin to other extensions directly

instead of using static val in companion.
2020-10-22 17:14:06 +03:00
Leonid Startsev 4ec90b18bc Rework DescriptorSerializerPlugin to be a part of Project's extensions
instead of statically registering it.

Static registering can cause subtle errors when plugin implementation
(e.g. SerializationDescriptorPluginForKotlinxSerialization) is registered
from multiple classloaders: in multi-module with daemon compilation scenario

 #KT-41857 Fixed
2020-10-22 17:04:35 +03:00
Ilya Kirillov db069c3264 Wizard: add compose desktop template 2020-10-15 21:47:08 +03:00
Vladimir Dolzhenko 7c2112d014 Prepare for KT dynamic plugin: make EP dynamic
Relates to ^KT-38518
2020-10-12 13:09:17 +00:00
Vladimir Dolzhenko ce1b388668 Add registry key kotlin.resolve.forceFullResolveOnHighlighting
Relates to ^KT-41195
Relates to ^KT-38687
2020-09-30 05:56:46 +00:00
Mikhail Zarechenskiy 8ff141357e as42: move plugin.xml to appropriate resource directy
#KT-41930 Fixed
2020-09-29 15:32:34 +03:00
Nikolay Krasko 2df030f583 as42: Apply 201 <-> AS41 diff 2020-09-29 15:32:32 +03:00
Toshiaki Kameyama bc580d2fd9 Introduce "Unused result of data class copy" inspection
#KT-34121 Fixed
2020-09-25 17:18:41 +02:00
Igor Yakovlev d534d92123 [FIR IDE] Implement FIR for KotlinUsageTypeProvider 2020-09-25 17:26:22 +03:00
Toshiaki Kameyama 37ba9eccc4 KT-31553 Complete Statement: Wrong auto-insertion of closing curly brace for a code block (#2378)
* Complete statement: wrap property initializer by run/when block

#KT-31553 Fixed
2020-09-25 16:04:03 +02:00
Yan Zhulanow 15b2850ee0 Parcelize: Add IDE support for the Parcelize compiler plugin with sources extracted from Android Extensions plugin (KT-40030) 2020-09-24 15:50:57 +09:00
Toshiaki Kameyama 6e8565917e MapGetWithNotNullAssertionOperatorInspection: decrease severity to INFORMATION
#KT-33096 Fixed
2020-09-23 14:52:14 +02:00
Vladimir Dolzhenko 4e5c61cd2f Notify if gradle points to invalid JDK
^KT-41141 Fixed
2020-09-23 09:44:07 +00:00
Toshiaki Kameyama d9cf4ee732 Add intention to evaluate compile time expression
#KT-40251 Fixed
2020-09-22 10:46:54 +02:00
Igor Yakovlev 75347d06b9 [FIR IDE] Move IconProvider in fir independed module 2020-09-15 11:25:06 +03:00
Igor Yakovlev e30f09d513 [FIR IDE] Separate find usages logic from descriptors 2020-09-15 11:25:06 +03:00
Vladimir Dolzhenko 6f03e42ef7 Revert back Inspection: convert initialized val to non-null type
Relates to ^KT-35757
Relates to ^KT-19321
2020-09-09 23:38:21 +02:00
Pavel Kirpichenkov 9d6bdc6fc4 Support modification tracking for source-dependent LibraryInfo
#KT-39734
2020-09-07 18:52:10 +03:00
Sebastian Kaspari 01143f24a4 Add KotlinClassConstructorInfoHandler for showing parameter info of parameterized super class constructor.
^KT-41617 Fixed
2020-09-07 13:23:08 +02:00
Toshiaki Kameyama 343010a833 "Unused equals expression" inspection: highlight whole expression with yellow background
^KT-41615 Fixed
2020-09-04 12:55:55 +02:00
Toshiaki Kameyama 8420c0b7c7 Add "Redundant nullable return type" inspection
^KT-19321 Fixed
2020-09-04 09:07:22 +02:00
Vladimir Dolzhenko 4f4db68a61 I18N fixes after merging convert initialized val to non-null type inspection
Relates to ^KT-35757
2020-09-03 22:01:11 +02:00
kvirolainen 18fbf5729d Inspection: convert initialized val to non-null type
^KT-35757 Fixed
2020-09-03 16:30:28 +02:00
Enteerman c3aeaa9052 Inspection: Simplify Nested forEach/onEach in also/apply to onEach
^KT-40283 Fixed
2020-09-03 15:29:32 +02:00
Dereck Bridie 94970e2d1e Intention to replace a = b with b.also { a = it }
^KT-22420 Fixed
2020-09-03 15:11:36 +02:00
Ilya Kirillov 3cd445563e FIR IDE: implement KotlinExpressionTypeProvider for FIR 2020-08-28 12:51:55 +03:00
Ilya Goncharov d5340803bd [JS, Wizard] Add react application template
^KT-41417 fixed
2020-08-27 13:34:15 +03:00
Dmitry Gridin 5f584691a6 [inspections] disable "Redundant inner modifier" inspection
^KT-41264 Fixed
2020-08-21 09:28:37 +07:00
Yunir Salimzyanov 70cda1b113 Refactor and fix files previously affected by 192 patchset (KTI-315) 2020-08-19 19:40:02 +03:00
Yunir Salimzyanov 42da9e62db Cleanup 192 patchset files (KTI-315) 2020-08-19 19:40:02 +03:00
Yunir Salimzyanov 27b2e16141 Cleanup as36 patchset files (KTI-315) 2020-08-19 19:40:00 +03:00
Igor Yakovlev c29dbee65e Cover move method refactoring with registry key (disabled by default) 2020-08-19 12:11:53 +03:00