Aleksey Dobrynin
25a39de77f
[java, jigsaw] Support JDK-8197532: add tests (IDEA-367339) IJ-CR-154794
...
(cherry picked from commit e3acb5c8848ae13da6f28c1593b432e27c81cd14)
IJ-CR-154794
GitOrigin-RevId: 881dcb8023063fcdd7116191c662b180986d4f93
2025-04-30 08:31:30 +00:00
Tagir Valeev
5e8306f8c8
[java-highlighting] Improve error message in IDEA-369310
...
Previous hasError status (after syntax error) was not reset. As a result, we did not report the next error on the surrounding element.
(cherry picked from commit 60c0be1cc6ca4967eb72e2fc24278cdc5cf2728e)
Review ID: IJ-CR-157915
GitOrigin-RevId: a44595d7b2e8fd472f6f084998901645bf29eab6
2025-03-20 10:59:14 +00:00
Tagir Valeev
22abc0a29b
[java-highlighting] IDEA-369310 NPE in error highlighter
...
(cherry picked from commit 0944d4f1c9594d138df85041748ff72fb56e436d)
Review ID: IJ-CR-157915
GitOrigin-RevId: 08a1d92218b7164b3683018cf8ce1e865eea7c24
2025-03-20 10:59:13 +00:00
Tagir Valeev
d3a7dcfa0a
[java-highlighting] Avoid highlighting outside of PsiField psi element
...
Fixes IDEA-368916 IAE in error highlighting when several fields are declared with shared modifier list
(cherry picked from commit 012b6564f9ca1a775894a3fc2b003c4feb2477e6)
IJ-CR-157290
GitOrigin-RevId: 4640510fdabda87e7b2da384f001f93c9bf64af1
2025-03-12 11:46:51 +00:00
Tagir Valeev
f4f49236b6
[java-highlighting] IDEA-368498 Errors about incorrect TYPE_USE annotations are not reported by IntelliJ IDEA
...
(cherry picked from commit 05b017fe457e4efaf0685d429bfd6c2e743936cb)
IJ-CR-156764
GitOrigin-RevId: 5b39f41262152741ae21b83e27f3f61e93ad74c2
2025-03-12 11:33:13 +00:00
Tagir Valeev
42ce63523e
[java-highlighting] checkModuleReference migrated to ModuleChecker and JavaModuleDefinitionInspection
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: b801fdbe22df163a4f0db153016ae50671ccc866
2025-02-19 20:42:37 +00:00
Tagir Valeev
9c4282bb5f
[java-highlighting] SwitchChecker.checkDuplicates migrated
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: 009041ed8f87c4b2af89849393f00388e912d95a
2025-02-19 20:42:37 +00:00
Tagir Valeev
9e458c909c
[java-highlighting] checkLabelSelectorCompatibility extracted and moved to SwitchChecker
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: bec076c5bff67e22d06e64e573d3219a4c89dd4d
2025-02-19 17:57:38 +00:00
Tagir Valeev
7bb33c7a68
[java-highlighting] SwitchChecker introduced
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: fb9494f104dd279e0e532781d04b85472e2c199f
2025-02-19 17:57:38 +00:00
Tagir Valeev
f8b210a481
[java-highlighting] Minor fixes in switch statement highlighting
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: 2924ae6c9984caa6e8a45f640c4de54e02134ad3
2025-02-19 14:57:00 +00:00
Tagir Valeev
cb626d5749
[java-highlighting] checkSwitchSelectorType migrated
...
Error messages unified; do not list allowed switch types anymore
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: 69675af87ac8866fb5ba1475094b93af07aa1ad5
2025-02-18 09:36:18 +00:00
Tagir Valeev
492c6bdaec
[java-core] JavaPsiSealedUtil moved to codeserver.core
...
GitOrigin-RevId: d4d5b683216563029bf817a964fbd020c33ac990
2025-02-18 09:36:18 +00:00
Tagir Valeev
47ea843d98
[java-core] JavaPsiReferenceUtil moved to codeserver.core
...
GitOrigin-RevId: acad9e3fddb54a91d678aead628c2124128e93f0
2025-02-18 09:36:18 +00:00
Tagir Valeev
f659d57b70
[java-core] JavaPsiEnumUtil moved to codeserver.core
...
GitOrigin-RevId: c4f14fb79181cebe0ff87f5830b64228c0937e70
2025-02-18 09:36:18 +00:00
Tagir Valeev
4abe8788e2
[java-core] JavaPsiSingleFileSourceUtil moved to codeserver.core
...
GitOrigin-RevId: 2368062535cd331747a871d22f405e4683ae8bd6
2025-02-18 09:36:18 +00:00
Tagir Valeev
eec026b0ea
[java-core] JavaPsiModifierUtil moved to codeserver.core
...
GitOrigin-RevId: 72b18a9acec8597aad73610937894f2c2e6d1b36
2025-02-18 09:36:18 +00:00
Tagir Valeev
d0e7c1e66e
[java-core] JavaPsiVariableUtil moved to codeserver.core
...
GitOrigin-RevId: d439121bd3795e5ffe13a43152c2a78973e24fcc
2025-02-18 09:36:18 +00:00
Tagir Valeev
e6691d9ea8
[java-highlighting] SwitchBlockHighlightingModel.checkSwitchBlockStatements migrated
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: 463b1549d45bf98586e6ae9dafb4bc4b330bbe52
2025-02-18 09:36:18 +00:00
Tagir Valeev
a0f777069b
[java-highlighting] move module-related warnings to JavaModuleDefinitionInspection
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: 66179a41da5e02b759f07f9d6638b87711181348
2025-02-17 12:04:21 +00:00
Tagir Valeev
2350d69472
[java-highlighting] JavaCompilationErrorBundle.properties proofreading (DOC-34381)
...
GitOrigin-RevId: 05bdca159a63027ea0d1e3d767d4adb9b258f47e
2025-02-14 12:45:24 +00:00
Aleksey Dobrynin
8f56022a99
[java, import-module] check import module ... in module-info.java (IDEA-367430) IJ-CR-154969
...
GitOrigin-RevId: 2033f5a1989191edb3701f380404ebf268caf822
2025-02-14 01:09:59 +00:00
Tagir Valeev
ed7a547a19
[java-highlighting] checkServiceImplementations migrated
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: f0e363434b7fb79523f7fef5b94c7445e1456a6b
2025-02-13 16:25:21 +00:00
Tagir Valeev
25ed837a4a
[java-highlighting] checkSwitchExpressionReturnTypeCompatible migrated
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: 833c73081ceed15c9c498e5e56dd142c165c2dca
2025-02-13 16:25:21 +00:00
Tagir Valeev
f58076f23f
[java-highlighting] checkClassReferenceAfterQualifier migrated
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: f11a0b224c8cdee5519452f61bcf8daf4470133e
2025-02-12 20:34:11 +00:00
Tagir Valeev
61f7252105
[java-highlighting] same erasure problems migrated
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: 052d3bf8a26c376c7dfc5b1e370e583cf6236138
2025-02-12 20:34:11 +00:00
Tagir Valeev
b9afbd19e8
[java-highlighting] more reference-related problems migrated
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: f8d8b9b8127803cc99d843c7691799501e6e193a
2025-02-12 20:34:11 +00:00
Aleksey Dobrynin
4f7c754f44
[java, import-module] check import module ... in module-info.java (IDEA-367430)
...
GitOrigin-RevId: a0ceb8386f1ba46f6c7221da15beb40742a2086b
2025-02-12 16:56:06 +00:00
Tagir Valeev
5d47c60541
[java-highlighting] more module-related problems migrated
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: e0b7381612b50ee09c7a5ff676aec5f14da6636d
2025-02-11 18:46:42 +00:00
Tagir Valeev
6fc7a8b6e5
[java-core] Split JavaServiceUtil
...
JavaServiceProviderUtil -> codeserver.core
JavaServiceLineMarkerUtil -> java-impl
GitOrigin-RevId: 65c42cdce19ab257ffd18143cc32ff4bd4aeacf7
2025-02-11 18:46:42 +00:00
Vladimir Krivosheev
e465d1ac3d
update bazel files
...
GitOrigin-RevId: 06d2aa1502e9c589453f8fb3d452ab7e9eaf0041
2025-02-11 17:05:10 +00:00
Tagir Valeev
fb57088d94
[java-highlighting] WRONG_REF type for CALL_AMBIGUOUS_NO_MATCH; constant highlighting type overload
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: 4edd0b09fe8f61d5098180abd93643f369071652
2025-02-11 15:54:30 +00:00
Tagir Valeev
44cc56f70e
[java-highlighting] some module-related problems migrated
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: 6dd89cd11a186b6ee704ca381f0c53b850ca9b22
2025-02-11 09:57:16 +00:00
Tagir Valeev
291c3cfbd9
[java-modules] More code moved to JavaPsiModuleUtil from JavaModuleGraphUtil
...
GitOrigin-RevId: 0a0e7d4bc713deb3d1d55857873c1f708da7a2af
2025-02-11 09:57:16 +00:00
Tagir Valeev
e7f402a2e9
[java-highlighting] checkPermitsList migrated completely; HighlightClassUtil migration finished
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: dc73c1168256fad8d274ce3d009f97fae35fb59f
2025-02-10 14:02:54 +00:00
Tagir Valeev
3e684ba9d0
[java-highlighting] checkExtendsSealedClass migrated
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: f97bc668d6713ab49e65c5f1bac6896407faa898
2025-02-10 14:02:54 +00:00
Tagir Valeev
014ec23e88
[java-highlighting] JavaErrorVisitor: get current module inside visitor
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: 91fdf9883b626732cc06e786161b0f464fe4d12c
2025-02-10 14:02:54 +00:00
Tagir Valeev
ef33586d9e
[java-highlighting] JavaErrorKind: remove validators (were almost unused)
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: 7a24260b0a408128caed8aac693fd5425dfc43a4
2025-02-10 14:02:54 +00:00
Tagir Valeev
fab48fb719
[java-highlighting] JavaErrorKind: anchor does not depend on context
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: e6bbe1bbff4eff16c66198b96b3f79fc095575f7
2025-02-10 14:02:54 +00:00
Tagir Valeev
178b721cf7
[java-highlighting] Preview warning migrated
...
Also improve reporting, different messages for errors and warnings; reflective preview use reported by inspection
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: d7c85058aed3202d0599fc879a61c0fa56388fea
2025-02-10 14:02:54 +00:00
Vladimir Krivosheev
154e1b1445
update bazel files
...
GitOrigin-RevId: fdb2c5a8fbaaa72b4fba7053f4178f89e2ff48d5
2025-02-08 11:42:47 +00:00
Tagir Valeev
9b9ed3498f
[java-core] Move JavaPreviewFeatureUtil to codeserver.core
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: 79db63637514eef45284a8535d8fa8d9bad129f7
2025-02-07 16:16:33 +00:00
Tagir Valeev
0e57ef0ef0
[java-core] Extract JavaPsiModuleUtil with minimized dependencies; new module intellij.java.codeserver.core
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: 328779172e877b737a68624fa09ea88cf5fd1954
2025-02-07 16:16:32 +00:00
Tagir Valeev
9314a671b8
[java-highlighting] checkSwitchExpressionHasResult migrated
...
Also use ControlFlow instead of ig ControlFlowUtils to check normal completion. Otherwise, it thinks that System.exit() doesn't complete normally
Also fix (hopefully) yield in finally in ControlFlowUtil.canCompleteNormally
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: efa0cd4b8f478b98e904186005b7802e958507ae
2025-02-07 12:04:27 +00:00
Tagir Valeev
c27cd7c481
[java-highlighting] checkResourceVariableIsFinal migrated
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: 2a786e61d8da816b6f85fa8ca8d4d0d1cdbab393
2025-02-06 10:35:32 +00:00
Tagir Valeev
7e1d0f2784
[java-highlighting] checkMemberReferencedBeforeConstructorCalled migrated
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: a8d2dba7d30b49ac7bdcc3e704334139a5139c2a
2025-02-06 10:35:32 +00:00
Tagir Valeev
41c378f2d8
[java-highlighting] Rest of feature level checks migrated
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: efd609b95f5859ecdd3040c301f943505d94b809
2025-02-06 10:35:32 +00:00
Tagir Valeev
631e06c624
[java-highlighting] Variable already defined error migrated
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: 6a53142a596abe2615151b36e06c3686013ac4b3
2025-02-06 10:35:32 +00:00
Tagir Valeev
abd0a30d7f
[java-highlighting] checkSelectFromTypeParameter migrated
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: 48d357bb48207d12143157ac0ba94b97ffda1f33
2025-02-06 10:35:32 +00:00
Tagir Valeev
1cd294e40d
[java-highlighting] The rest of control-flow-related stuff (checkFinalVariableMightAlreadyHaveBeenAssignedTo) migrated
...
More utility methods inside ControlFlowUtil
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: d4c294ce18da2032a0686f66794a7f377549edd2
2025-02-06 10:35:32 +00:00
Tagir Valeev
cc643a5ae4
[java-highlighting] More control-flow-related stuff migrated
...
Part of IDEA-365344 Create a new Java error highlighter with minimal dependencies (PSI only)
GitOrigin-RevId: 3c292fdf4869e6d13c16fabbf42e2055ea54f724
2025-02-06 10:35:32 +00:00