Commit Graph

21363 Commits

Author SHA1 Message Date
Max Medvedev
c4476fce2c IJPL-160728 SuppressDetectingInspection can be non-dumb aware
GitOrigin-RevId: e76b9fb448e6a38d23249684dc77b4e44d8911a9
2024-08-24 22:33:25 +00:00
Anna Kozlova
662d144bf9 [rename] remove artificial command in tests
- in production there is no top level command which leads to differences, and the test does not catch bugs like IDEA-358141 anymore

GitOrigin-RevId: 56f27a8ddf6c9e3c4d92aaf2510b007914b1ec1a
2024-08-23 12:02:39 +00:00
Gregory.Shrago
f678ef232d introduce ActionUiKind: cleanup
GitOrigin-RevId: 3064d1b5f9cdd83c3b9d0b22d0dd489d0213fba9
2024-08-22 17:24:58 +00:00
Mikhail Pyltsin
e01d24d5c8 [java-highlighting] IDEA-357866 Spurious "Different case kinds used in the switch" error on incomplete code
- fixes
- not double error messages

GitOrigin-RevId: 8f789243ee4e09d3eb8de6a2db7dcbe25ee517db
2024-08-22 16:03:56 +00:00
Mikhail Pyltsin
cd14483af8 [java-highlighting] IDEA-357866 Spurious "Different case kinds used in the switch" error on incomplete code
- improve error message

GitOrigin-RevId: 2a8da472e07dd10bdb0ae75e679b6056ab884b72
2024-08-22 16:03:56 +00:00
Bas Leijdekkers
affc8566c8 Java: show duplicate throws tags in Javadoc (IDEA-345275)
GitOrigin-RevId: 8487e9cdbea877c548500b9718f3de1ddd02f322
2024-08-22 15:27:14 +00:00
Bas Leijdekkers
1a5e213e96 Java: "Suppress for <x>" fix should not make code uncompilable (IDEA-358115)
GitOrigin-RevId: 754d0bac805a0e9d56489c63e5486d6e7e15a4db
2024-08-22 15:27:14 +00:00
Bas Leijdekkers
c9cf2bb994 Java: test cleanup
GitOrigin-RevId: fa220363a66fc7a3a0c7108b8d81ae3d153dd7ba
2024-08-22 15:27:14 +00:00
Bas Leijdekkers
e2e6809274 Java: avoid infinite loop when creating switch branches for enum with duplicate constants (IDEA-357561)
GitOrigin-RevId: e9c84396786baceb58501a56d5d7e529f5ae9276
2024-08-22 15:27:14 +00:00
Alexey Kudravtsev
05ca25248d IJPL-160136 Blinking highlighting on refactoring TS code
Rework the "when to remove highlighters for invalid PSI" heuristic.
Instead of removing them immediately for dirty document regions, recycle them all, in the hope that some languages with poor incremental reparse support will reuse them, event in the dirty regions, e.g. during massive refactorings.
If after some short time (500ms currently, highlighting.delay.invalid.psi.info.kill.ms) these invalid psi highlighters are not reclaimed, kill them to improve responsiveness of removing outdated infos.

GitOrigin-RevId: b5b52c72d7fac0eaab18a5a696b32ae74096ff89
2024-08-22 14:25:38 +00:00
Ivan Fomenko
ec3b7d382c IDEA-259784 Type hints: show implicit types of lambda parameters
GitOrigin-RevId: 586b24be8f16e61de4e02c588fa5b3546d34ff41
2024-08-22 12:33:01 +00:00
Alexey Kudravtsev
d0a029f7ab cleanup: more readable tostring, avoid hardcoding tostring in tests
GitOrigin-RevId: ce336c204bcb11fd5d033b6fe4a377dad932c66e
2024-08-22 10:58:09 +00:00
Mikhail Pyltsin
e39d914c56 [java-highlighting] IDEA-357868 Better error message for primitive types in instanceof
GitOrigin-RevId: bb638cf01ec27474d89859c27c5410add6be5931
2024-08-22 09:22:53 +00:00
Mikhail Pyltsin
cbc5e8cd2d [java-action] IDEA-356782 Incorrect place of caret into text block with injection after enter
- introduced JavaEnterInInjectedTextBlockHandler

GitOrigin-RevId: 7085ebb8d23177b11f49da17df2eb7df98f39b8a
2024-08-21 18:41:23 +00:00
Bas Leijdekkers
25896445a0 [java-property-tests] no longer necessary to ignore clone() generation
GitOrigin-RevId: bbc5e510e2abc6f9f8401b7ca102fb44f7685f93
2024-08-21 09:12:08 +00:00
Bas Leijdekkers
7db980cfcf Java: remove unneeded ':' from inspection problem report
GitOrigin-RevId: 9b0c070c8ca2a883d0d07f0064b67f22594cbced
2024-08-21 09:12:08 +00:00
Bas Leijdekkers
bd7f1f4270 Java: proper order of 'true' and 'false' in quick-fix name (IDEA-357973)
also fixes internationalization and the incorrect comma in the name
for "Create missing switch branches" quick-fix

GitOrigin-RevId: 16285e054447d8d15318df8889499bbbf91243a7
2024-08-21 09:12:08 +00:00
Aleksey Pivovarov
0a6fd8e8f0 editor: store FileEditorManagerImpl keys in one place
GitOrigin-RevId: d16c9d1b4b4d6e3cabf484de5ffe4d97f2442c6f
2024-08-20 13:29:05 +00:00
Alexey Kudravtsev
9e7a3e5152 tests: fix "Access from EDT is not allowed" exception when waitForTermination() tries to steal work from FJP in EDT
GitOrigin-RevId: 28e17546ff435975b87066cb8ba77574042229ac
2024-08-20 12:02:17 +00:00
Alexey Kudravtsev
877dee4f7e more correct test: manifest error dialog sooner, before the next highlighting does that implicitly
GitOrigin-RevId: 87351941264a1e2447431d476a257a55b85e9196
2024-08-20 12:02:17 +00:00
Mikhail Pyltsin
46c33c46e3 [java-intention] IDEA-357879 "Replace catch sections with throw" intention doesn't check ancestors
- fix test's flakiness

GitOrigin-RevId: ce2d52a107441215c5c8f953916e2203196fbc25
2024-08-19 23:46:04 +00:00
Mikhail Pyltsin
6d84f1e4df [java-intention] IDEA-357879 "Replace catch sections with throw" intention doesn't check ancestors
GitOrigin-RevId: ab1f6d8c13b76850481b38c3fe0137f22fc11071
2024-08-19 20:00:05 +00:00
Mikhail Pyltsin
2954ea71d0 [java-completion] Basic completion does not complete case keyword with default case
GitOrigin-RevId: 7e4f78bfb981202f90ae7d75302753a71055599c
2024-08-19 17:51:59 +00:00
Mikhail Pyltsin
6cd1f1a858 [java-property-tests] JavaOutOfClassDefinitionPropertyTest.java uses waitForAsyncTaskCompletion
GitOrigin-RevId: 18112835a976e875e85b77268db88857fbe1c64e
2024-08-19 17:36:48 +00:00
Mathias Boulay
f95cbb9677 fix(JavaDoc): better autocomplete
GitOrigin-RevId: 64cc8794d732cd08566413b0070b371768e47d8f
2024-08-19 10:39:25 +00:00
Max Medvedev
771364b2e4 don't instantiate all inspections in dumb mode
IJPL-574, IJPL-160462

GitOrigin-RevId: c47be295416b50cf08aa013e818e1bfae4cc607e
2024-08-19 09:23:00 +00:00
Max Medvedev
b118f713ab introduce StorageUpdate interface
GitOrigin-RevId: 610d4ba045deab0724494d3422b2373b3e18ded8
2024-08-17 10:06:10 +00:00
Mikhail Pyltsin
c56e5e7313 [java-inspections] IDEA-357725 LoggerInitializedWithForeignClassInspection should skip when the logger is the final field
GitOrigin-RevId: e910d9bb094f058c363148a3d08b695276bcc2c6
2024-08-15 18:02:00 +00:00
Bas Leijdekkers
adbb319537 Java: handle multiline headings a little better (IJ-CR-142291)
GitOrigin-RevId: 0c132d6b41dfc634c15bbe47d8176612909cf3f7
2024-08-15 15:56:37 +00:00
Bas Leijdekkers
31cd07cef6 Java: avoid exceptions on bad javadoc html (IJ-CR-142291)
GitOrigin-RevId: 40fe350fab9354863141929cd135a5f2d0393fc2
2024-08-15 15:56:37 +00:00
Gregory.Shrago
1f8f8acf33 drop trivial getDataForItem overrides
GitOrigin-RevId: 3bb46d30fc88d19510c8c6aba6d15b1dba839f03
2024-08-15 08:03:57 +00:00
Mathias Boulay
abd7b1dded fix(JDoc): Formatting and inspections issues
GitOrigin-RevId: 910e9b3335fa7c3967fb79893ecba7c69595a201
2024-08-14 18:24:38 +00:00
Mathias Boulay
6ebdc205ef feat(javadoc): early markdown support part 2
GitOrigin-RevId: 74093daa489fda535b3951828d6617519e5d293f
2024-08-14 02:45:23 +00:00
Alexey Kudravtsev
6652280052 rewrite file-level highlighters to make them behave just like regular ones
, to fix problems when many file-level infos with always changing descriptions are generated by one tool, e.g. when LargeFileAnnotator generates a different file-level highlighter on every typing

GitOrigin-RevId: f68527d9f3767535247b3680eaa8b26892f940bf
2024-08-13 19:37:41 +00:00
Alexey Kudravtsev
b7e62ca44a fix incorrect assertions, cleanup
GitOrigin-RevId: a24d7f7b859c58c4932519d69d6ec04e294aa630
2024-08-13 15:05:29 +00:00
Mathias Boulay
3825899d51 feat(IDEA-353092): early markdown jdoc support
GitOrigin-RevId: 8c02012551f1a97d3f5d6aed021889911b138b28
2024-08-13 11:44:06 +00:00
Louis Vignier
6a4b505aaf [java-property-tests] JavaCommentingStrategy: exclude "Replace 'catch' section with 'throws' declaration"
GitOrigin-RevId: 02364c18ae5c839ec019bd33d9f73c814459eed0
2024-08-13 09:54:17 +00:00
Louis Vignier
a19d6804d9 [java-property-tests] Wait for coroutines in inlineExtractMethodCompilation
When extracting, previous changes might have been reverted, causing the test to fail.

GitOrigin-RevId: e669792210ba96f15e1f1f3ef14aacd5afd2fede
2024-08-13 09:54:17 +00:00
Louis Vignier
9e43abe887 [ui] Set initial caret position to 0 in VM options
IJ-CR-140588

GitOrigin-RevId: 8cb6554e403485d6241ce4733052b2b1a7f65957
2024-08-13 09:54:17 +00:00
Mikhail Pyltsin
d8b8f63677 [java-inspections] IDEA-356745 False positive 'Incorrect 'MessageFormat' pattern' when argument is array
GitOrigin-RevId: 75b8f2d944f05ab124e0b1ac340383dcc240b885
2024-08-12 20:28:37 +00:00
Bas Leijdekkers
21d8008ff1 Java: don't break indentation of element after javadoc comment when converting to markdown
GitOrigin-RevId: df6e25727b13fe229531eb2636dcfafa9cb8a175
2024-08-12 17:37:07 +00:00
Bas Leijdekkers
426cda83e6 Java: support xhtml self-closing tags
GitOrigin-RevId: 97e23cb2054fc721e57a2017b952f35351675220
2024-08-12 13:37:26 +00:00
Alexey Kudravtsev
62b88e8fe3 fix fileStatusMap.getCompositeDocumentDirtyRange() optimization which sometimes returned whole file always
GitOrigin-RevId: af444762564d2fe8fe3d6915db7fa35861546657
2024-08-12 13:10:04 +00:00
Alexey Kudravtsev
c806c607c9 IJPL-159317 IDE highlights syntax in the comment
rework the HighlightInfoUpdater to avoid obsolete error elements stuck in the markup
The problem was in the several highlighting sessions overlapping each other when the one session was canceled but still lingered on while the other started and progressed far enough.
The two sessions called setHighlightersInRange() in HighlightInfoUpdater in reentrant fashion which could lead to some highlighters to be forgotten by HighlightInfoUpdater internal data structures. The fix is to refactor HighlightInfoUpdater to guarantee that the highlighters registered there are always contained in the markup and vice versa.
Several testcases added to DaemonRespondToChangesTest where the test invokes typing, then waits for the daemon to start, then proceed to another typing, effectively canceling the daemon process very frequently to induce the session overlappings and then checking that no error element highlighters are left in the markup

GitOrigin-RevId: 9b72068d71b28d940c3e9fdb98574c78e4776800
2024-08-12 11:27:32 +00:00
Alexandr Suhinin
13a49ea232 [extract method] decouple settings from the extract template
GitOrigin-RevId: a628ca0ecfa302e9920c315e7adacc14471b6053
2024-08-12 09:29:26 +00:00
Max Medvedev
70c0a3c550 IJPL-574 run inspections in dumb mode
GitOrigin-RevId: 303e9eb0d08645854be047d2630add0b7ed04be2
2024-08-09 20:25:06 +00:00
Max Medvedev
c0f11e5298 HighlightDisplayKey: introduce proper getShortName instead of toString
GitOrigin-RevId: 7c6fb37449dbebb6308c3d76f4cbb48bb3cc1392
2024-08-09 20:25:06 +00:00
Bas Leijdekkers
1c2887a09c Java: basic support for headings when converting Javadoc to Markdown
GitOrigin-RevId: 0b8d1dcfa1324ff783a9b412b6fb330bbc6b0646
2024-08-09 11:14:15 +00:00
Bas Leijdekkers
ebbf5a1d20 Java: fix <br> support when converting Javadoc to Markdown
GitOrigin-RevId: d85489271ee65ff043f039eda4bfa82f8e50db77
2024-08-09 11:14:15 +00:00
Mikhail Pyltsin
cb37003541 [java-inspections] IDEA-357323 Propose case null during adding all cases
GitOrigin-RevId: 6d7ffccc28d64ed0f52db0235c41796d1d81284e
2024-08-09 11:00:42 +00:00