Commit Graph

660 Commits

Author SHA1 Message Date
Tagir Valeev
193b2cb477 [java-inspections] Experimental ModCommand-based DeletePrivateMethodFix for unused inspection
GitOrigin-RevId: efd9306505048695f1aa1de1851383e170b0c1ca
2024-03-12 16:55:18 +00:00
Evgenii Zakharchenko
c2db9ae649 [ultimate] IDEA-346716 Spring beans auto-injection via completion: scroll jumps to the top
GitOrigin-RevId: 84e1685d43d9c54e5d7452647a227e3532be47b6
2024-03-01 19:19:54 +00:00
Tagir Valeev
d89c17fc59 [kotlin-dfa] Move inspection.data.flow.warn.when.reading.a.value.guaranteed.to.be.constant to JavaAnalysisBundle
Preparatory step for KTIJ-28908 Convert "Constant conditions" inspection to K2

GitOrigin-RevId: 68798782d260f8245947423efd936ae82bde841c
2024-02-24 12:22:09 +00:00
Evgenii Zakharchenko
4deae98f45 [ultimate] IDEA-346716 Spring beans auto-injection via completion: scroll jumps to the top
KTIJ-28883 Do not suggest a live template for Kotlin quick fix if there are no available variables

GitOrigin-RevId: 65642a313c337517083830878b72a8b678230233
2024-02-22 22:38:26 +00:00
Aleksey Dobrynin
1b565a13b9 [java, quickfix] Refactor module access checking method and improve module naming. IJ-CR-125003
GitOrigin-RevId: 078deb60a0fbf497020fe73bd99e170171a30381
2024-02-16 11:31:20 +00:00
Tagir Valeev
64327f79d6 [java-inspections] IDEA-346242 Add 'minimal java version' clause automatically to inspection descriptions, based on the required feature(s)
GitOrigin-RevId: 50a25148d4d36c46e9552b3123d1ef966b40a2c2
2024-02-15 15:28:00 +00:00
Tagir Valeev
47a98d4500 [java] LanguageLevel#feature method; javadoc
GitOrigin-RevId: f3c57f7101b3ce7369c66b97411c897bdcd46d24
2024-02-15 13:23:21 +00:00
Tagir Valeev
2aa52eea2d [java] IDEA-345517 Feature-based support of unsupported preview language levels
GitOrigin-RevId: 3037d36588c239d6236ba64a7df2bf2a3b51cba4
2024-02-12 19:12:39 +00:00
Tagir Valeev
a7674dca70 [java] IDEA-345355 Refactor HighlightingFeature (in progress)
Create JavaLanguageFeature; move HighlightingFeature functionality there; move preview highlighting related utilities to new PreviewFeatureUtil class

GitOrigin-RevId: 116bcc9feb6fb40a0bd6a25ba10c2f35b41ffea6
2024-02-08 10:07:12 +00:00
Alexey Kudravtsev
8dc9393675 cleanup: get rid of mutable stuff (part of KTIJ-26893 K2: Create*FromUsageFix fix)
GitOrigin-RevId: 9504fa61ca4d88d2b01f837d0d00ca7d4768f93f
2024-02-06 22:38:17 +00:00
Alexey Kudravtsev
18b384f5d9 fix typos and incorrect links in javadoc
GitOrigin-RevId: 25daa667902e8ffac4612306b6c6e2019873ae2b
2024-02-06 22:38:12 +00:00
Dmitriy.Panov
103eee0118 Revert "fix typos and incorrect links in javadoc"
This reverts commit b0a6236002781f491a71059c7d96ee625717bfa0.

GitOrigin-RevId: 8d1bcb419b22ab480f7a5f3d10fef0edd1582dba
2024-02-05 23:42:36 +01:00
Dmitriy.Panov
0bace9e4a0 Revert "cleanup: get rid of mutable stuff (part of KTIJ-26893 K2: Create*FromUsageFix fix)"
This reverts commit c9d8c5845babc20e58a38f0dc2d83363ff7378d3.

GitOrigin-RevId: 1fd74bfc8c347e5ed633f662f2e19978d25c7d64
2024-02-05 23:42:35 +01:00
Alexey Kudravtsev
7a79a8bf2a cleanup: get rid of mutable stuff (part of KTIJ-26893 K2: Create*FromUsageFix fix)
GitOrigin-RevId: c9d8c5845babc20e58a38f0dc2d83363ff7378d3
2024-02-05 19:01:06 +00:00
Alexey Kudravtsev
c77511e324 fix typos and incorrect links in javadoc
GitOrigin-RevId: b0a6236002781f491a71059c7d96ee625717bfa0
2024-02-05 19:01:01 +00:00
Mikhail Pyltsin
e467d25f90 [java-completion] IJ-CR-124074 IDEA-342465 support correctness for completion
- rollback changes for `createDeleteDefaultFix`

GitOrigin-RevId: 2bd379fe147da2ef83dca1efdc6af381e0b57c56
2024-02-02 16:39:17 +00:00
Tagir Valeev
5cc6eb573f Revert "[java-intentions] A simple generic rename mod-command based intention; used in createRenameFix to avoid creating a descriptor."
This reverts commit ac583b578e486be3a679fc22f373a53b5fdfe596.

GitOrigin-RevId: 822ad73092935356065fd6b5499cd15b060bb85c
2024-02-01 10:31:53 +00:00
Aleksey Dobrynin
0d8b737e97 [java, kotlin, quickfix] Add dependency in a single step while using Jigsaw modules. IDEA-341660
GitOrigin-RevId: 7c0ad3a4079ca76c1f1afb4147498e0ae08cc449
2024-01-30 14:29:06 +00:00
Mikhail Pyltsin
df015bbcf7 IJ-CR-124074 [java-completion] IDEA-342465 support correctness for completion
- DeleteDefaultFix to PsiUpdateModCommandAction
- delete measureTime for JavaCorrectnessChecker

GitOrigin-RevId: 3ba81bc4b5971257988efe37d85ac586396908cf
2024-01-29 20:59:21 +00:00
Tagir Valeev
165421c59d [java-intentions] A simple generic rename mod-command based intention; used in createRenameFix to avoid creating a descriptor.
GitOrigin-RevId: ac583b578e486be3a679fc22f373a53b5fdfe596
2024-01-29 16:51:36 +00:00
Mikhail Pyltsin
897bfa4e1c [java-completion] IJ-CR-124074 IDEA-342465 support correctness for completion
- Allow running highlighting on the copy of the file. Add comments

GitOrigin-RevId: c568202e7b1462834ab70fbdb1c3bd0bac448c92
2024-01-22 13:42:28 +00:00
Mikhail Pyltsin
82ae6a7e59 [java-completion] IDEA-342465 support correctness for completion
GitOrigin-RevId: e7d3dd5c9afec757fe2fcfb40499f7f174778264
2024-01-12 17:41:48 +00:00
Bas Leijdekkers
176a8e0bec Java: statements before super() part I (IDEA-340403)
GitOrigin-RevId: 7307a469267746ed3432acd1e73c894ccc87a254
2023-12-28 17:39:19 +00:00
Tagir Valeev
f7074186ea [java-inspections] PreviewFeatureInspection: add features from Java 20-22
Fixes IDEA-340983 Preview API (structured concurrency) usage in Java 21 is not highlighted

GitOrigin-RevId: cd02d5e1fe328104a47ac1fd684b2e2324b6558d
2023-12-14 15:51:27 +00:00
Tagir Valeev
6e1d684df0 [java-inspections] UseHashCodeMethodInspection: support double type
Also: fix comment processing
Improvement of IDEA-338114

GitOrigin-RevId: 87d057ccbea4262c40e2717c2ea3c004ac9865b0
2023-12-11 21:37:14 +00:00
Mikhail Pyltsin
3f86cf9292 [java-highlighting] IDEA-339935 JEP 463
- rename unnamed classes to implicitly declared classes

GitOrigin-RevId: 2c6d7f16a1dc6d2371b8f8b5f5675246c9bc99f9
2023-12-11 15:49:28 +00:00
Tagir Valeev
2a4fc312fb [java] IDEA-327241 Enable compilation and running Java projects with configured unsupported preview versions
GitOrigin-RevId: df85f51ac1d4249ec3baf34f5ce7d150e06d2a13
2023-12-09 13:20:33 +00:00
Tagir Valeev
3d075de8e5 [java] LanguageLevelUtil: fold ourPresentableShortMessage filling into the loop
GitOrigin-RevId: 7bd9e5390e7740163d18ea4f129148843686652f
2023-12-09 12:53:09 +00:00
Bas Leijdekkers
0b59d209aa Introduce language levels for Java 22
GitOrigin-RevId: cbc48e46a05c15e13d3c5e23cf32ae5f958ef615
2023-12-07 00:58:17 +00:00
Bas Leijdekkers
a50138d2c8 Java: improve javac quirks inspection texts (IJPF-CR-15669)
GitOrigin-RevId: fa038ac62b8f9e0a4fd56a483578741a353e0886
2023-11-29 20:30:35 +00:00
Andrey Cherkasov
f6af5745f7 [llm] Declare the text attribute for internal actions in plugin.xml
instead of using property files, as we do not intend to localize all internal actions.

IJ-CR-120022

GitOrigin-RevId: bdf91572dd59128131e54537f382851acf29a762
2023-11-20 11:11:06 +00:00
Yuriy Artamonov
55084d2618 [java] Make usages of OuterModelsModificationTrackerManager less verbose
GitOrigin-RevId: eb38feae25335f7a3a2d676e34409fa3d63f70de
2023-11-19 13:07:05 +00:00
Tagir Valeev
2770254f2f [java-inspections] IDEA-338114 Suggest to replace (int)(v ^ (v >>> 32)) with a Long.hashCode(v)
GitOrigin-RevId: 2d9591f9d9a558c4a61ac226556ef9f551d6e0c2
2023-11-15 21:43:17 +00:00
Andrey Cherkasov
b22e497d8c [llm] StatisticCollectorAction: cleanup
See description of the "Eager creation of action presentation" inspection

GitOrigin-RevId: 3e05c90a81afe8cd1a178ce243b503523dd7b0b5
2023-11-14 11:42:13 +00:00
Tagir Valeev
17a223b66d [mod-command] NullableNotNullManagerImpl: OptionController; used in ChangeNullableDefaultsFix
GitOrigin-RevId: 66d6128248cd06e81cb3ec7826265ea4a23b7dbf
2023-11-14 11:01:16 +00:00
Alexey Kudravtsev
9b4cc7a05d new inspection: "missorted imports" with quick-fix-only severity, to fix IDEA-334084 No "Optimize imports" action is displayed
GitOrigin-RevId: 92028252fc0b4c8ab05b7236de15ff44090a7183
2023-11-08 14:55:31 +00:00
Bas Leijdekkers
8cbdbab21a Java: move old check to quirks inspection
GitOrigin-RevId: f1201462a504c09c1d4ca10e813c343d03be55ac
2023-11-06 11:16:53 +00:00
Mikhail Pyltsin
19eded43f9 [java-highlighting] IJ-CR-118438 IDEA-315469 Quickfixes for switch labels with 'default'
- rebased to ModCommandAction

GitOrigin-RevId: dbb4b099ba7fbd0d8bc57068ade1cea5e77f40bb
2023-11-03 12:40:03 +00:00
Mikhail Pyltsin
3d7a18e986 [java-highlighting] IDEA-315469 Quickfixes for switch labels with 'default'
- fix to reverse 'case default, null'
- fix to replace 'case default' with 'default'

GitOrigin-RevId: 3762a40c859bb7a13a638614b3200b0005d8e85a
2023-11-01 10:23:57 +00:00
Tagir Valeev
943bacb4c0 [java-inspections] AnnotateMethodFix: mod-command
Now, works for in-code annotations only (but may work in batch). Was used for MissingOverrideAnnotationInspection and NullableStuffInspectionBase. The later uses old code now, as external annotations could be desired there.

Part of IDEA-322693 Migrate as much as possible Java intentions and quick-fixes to ModCommand API

GitOrigin-RevId: f580467c5e64782a629bbe7a48b7f95686f6b83c
2023-10-24 16:54:33 +00:00
Tagir Valeev
83ad94ff1f [mod-commands] IDEA-333040 Convert CompositeIntentionQuickFix to ModCommand
GitOrigin-RevId: 67fd2853544b99e94e442566d29d874990292d9f
2023-09-21 16:08:02 +00:00
Yuriy Artamonov
c53774e2fc [inspections] IDEA-321711 Use optimized PsiElementVisitor implementations
GitOrigin-RevId: 18ebc32aec877f71cd185ee7072dd139c076e9a3
2023-09-16 15:18:22 +00:00
Tagir Valeev
66d3646f6d [java-inspections] IDEA-331613 "Overridden parameter annotations" lint should be "Overriding"
GitOrigin-RevId: 7234832a572304695efe2fd21af60127679715df
2023-09-15 10:19:11 +00:00
Roman Ivanov
31928210fc [java] add move all members to class fix
GitOrigin-RevId: f5ad44f993f2f386c9847dc57ddac86cb4cf45d2
2023-09-07 08:48:06 +00:00
Alexey Kudravtsev
2da4d92224 make myLanguages thread-safe, optimization: reduce garbage
GitOrigin-RevId: b1d67c86b2779ee6be889c602b2a8d952b65fce3
2023-08-31 16:27:59 +00:00
Roman Ivanov
739e54a28e [java] delete "move member into class" as error elements are not created for such members
GitOrigin-RevId: c50d6e0c6de204c5f290047f1ff99bf11ef14a4d
2023-08-27 21:24:06 +00:00
Roman Ivanov
5067549319 [java] add fix for adding main method to unnamed class IDEA-326263
GitOrigin-RevId: b37c5261785815c8768535d3bd7934d86652777e
2023-08-27 21:23:25 +00:00
Roman Ivanov
4ef891cf5e add unnamed class feature and check for usage
GitOrigin-RevId: 51ab72778378fdf84d19cb801b10ef9fb1eb2929
2023-08-27 21:23:12 +00:00
Tagir Valeev
6495c1370c [java-dfa] IDEA-327154 String templates support in data flow inspection
GitOrigin-RevId: da9176e33611213fa6ab49ef1aba03d8550c2c12
2023-08-04 15:20:03 +00:00
Alexey Kudravtsev
3a577a0ac1 remove harmful suppressions
GitOrigin-RevId: f3fc94795f1037e4265e5fbc2e485b8811578036
2023-08-03 18:24:49 +00:00