Commit Graph

451311 Commits

Author SHA1 Message Date
Alexey Belkov
bfe72d1ba0 [kotlin] J2K: move MergePropertyWithConstructorParameterProcessing to common module
KTIJ-30760

GitOrigin-RevId: 1536a8b117fbfcdebce2b1b294dfc41c76d08c79
2024-08-09 19:19:40 +00:00
Alexey Belkov
d746994dcd [kotlin] J2K: move function to common module
KTIJ-30760

GitOrigin-RevId: 7f0c4b537b0f9f057c93bbecaa706b8d7ca19948
2024-08-09 19:19:40 +00:00
Alexey Belkov
eabbd496e2 [kotlin] J2K: Migrate MergePropertyWithConstructorParameterProcessing to AAPI
KTIJ-30760

GitOrigin-RevId: ff18e0f9ecf09fc570f8a208043b03010c2212c6
2024-08-09 19:19:40 +00:00
Alexey Belkov
de80468e0a [kotlin] J2K: Migrate K2ConvertGettersAndSettersToPropertyProcessing to AAPI
KTIJ-30693

GitOrigin-RevId: 0f1292061d2ba69c7781cdca45901a9ff36173a8
2024-08-09 19:19:40 +00:00
Alexey Belkov
73e6a9b95d [kotlin] J2K: Rename file
KTIJ-30693

GitOrigin-RevId: 217f25805840d342f835b743a9fa4904054f128e
2024-08-09 19:19:40 +00:00
Alexey Belkov
01268d55e7 [kotlin] J2K: Recreate K1 ConvertGettersAndSettersToPropertyProcessing
KTIJ-30693

GitOrigin-RevId: ba43a38ee01fdbc894b0c19ce00dc4ae368a76d0
2024-08-09 19:19:40 +00:00
Alexey Belkov
ed954c5ca9 [kotlin] J2K: Move ConvertGettersAndSettersToPropertyProcessing to K2
This is an intermediate commit to preserve git file history.
The code doesn't compile yet.

KTIJ-30693

GitOrigin-RevId: 6a56798bc1b0396b519f15005f59e5cfee08c68b
2024-08-09 19:19:40 +00:00
Alexey Kudravtsev
6a74b2ff01 highlighting cleanup: rename for clarity
GitOrigin-RevId: 548003cab49fd81077cd43b767a74688cb260383
2024-08-09 19:14:35 +00:00
Peter Gromov
6d9f37b644 [grazie] IJPL-89683 Don't check files with too much text
GitOrigin-RevId: 8a69c41dacaeb70e334bd8868d704847d1db7c5e
2024-08-09 19:13:56 +00:00
Ilya Kirillov
e6dee04311 [kotlin] fix exception VfsRootAccess$VfsRootAccessNotAllowedError: File accessed outside allowed roots in GotoWithMultipleLibrariesTest
Reproduced locally, the fix is to compile the jar into a known allowed tmp test dir.

GitOrigin-RevId: 3a218a8f1437d55a266bf959e362331fc3a74837
2024-08-09 19:06:53 +00:00
Ilya Kirillov
3e42f78fcc [kotlin] Do not use resolve/LC in go to class/symbol for Kotlin
Instead, implement the functionality via Kotlin declarations. Previously, it worked in a mixed mode: some declarations were provided via LC, some via Kotlin declarations.

Additionally, this change makes Kotlin "go to symbol/class" fully dumb-aware.

New behavior:
- All declarations are now provided via plain Kotlin declarations.
- No Light Classes are used:
  - To avoid using LC, `PsiShortNamesCache` is adapted in a way that it can ignore `PsiShortNamesCache` implementations which are explicitly marked as producing generated declarations instead of existing Java-based PSI like `PsiClass`, `PsiMethod`, etc.
    - `KotlinShortNamesCache` is marked as such, so it's ignored.
- As no resolve is used, all Kotlin contributors work in dumb mode.
- For facade declarations, like callables (functions or properties) from a facade or a facade class itself, new Kotlin contributors create new `PsiElementBasedNavigationItem`:
   - It points to the original Kotlin declaration (or to a `KtFile` in the case of a facade class itself).
   - In go to class/symbol action, duplicated declarations are merged with the original ones, so they are used only for text search purposes.
     - It's reflected in the tesdata updates
- `GotoSymbolModel2.getFullName` is updated so it can handle not only `PsiElement` but also a `PsiElementNavigationItem`
- Behaviour of qualified name is stabilized:
  - Previously, it produced `(in Container).Foo` for LC-based classes and `Container.Foo` for plain Kotlin classes.
  - Now, it always produces `Container.Foo`
       - It's reflected in the tesdata updates

^KTIJ-30913 fixed
^KTIJ-30842 fixed

GitOrigin-RevId: c671f6e161dd530e19e8abbbc7046f1cd121908d
2024-08-09 19:06:53 +00:00
Ilya Kirillov
893f5823dd [kotlin] add new tests for go to symbol
KTIJ-30913

GitOrigin-RevId: bec344b54790bb60b5f34afc237e5ff6a49e5c1f
2024-08-09 19:06:53 +00:00
Ilya Kirillov
4a326b22bf [kotlin] Check more information in GotoTest
Additionally, move the expected output to a separate file

KTIJ-30913

GitOrigin-RevId: 0c3aeca921f42b2245ced74aefbc20fdbc016899
2024-08-09 19:06:53 +00:00
Konstantin Aleev
69b6a980fa [yaml] key completion insert handler: fix removing lookup if the rest is compound value
GitOrigin-RevId: dc7fdf233b0e13ce3d3b7035e0231f07ab3b9296
2024-08-09 18:43:50 +00:00
Peter Gromov
9462202200 speed up indexing: don't intern AST leaf texts when parsing
GitOrigin-RevId: eecd30340170fea26620fc244a2114e3c7881983
2024-08-09 18:32:16 +00:00
Peter Gromov
61a2df00b5 IJPL-156597 Grammar rules should not be triggered on HTML classes
GitOrigin-RevId: 53010d82b8945d0c90a360b201664beabdd8417e
2024-08-09 18:32:16 +00:00
Peter Gromov
a3a6657b74 [grazie] IJPL-149625 Inconsistency between inspection details and settings
GitOrigin-RevId: 9996d1236d0595fe299c27703444624e0a868813
2024-08-09 18:32:16 +00:00
Ruslan Cheremin
8889c00ee9 [indexes] IJP-1365: specialized serializer for IdIndex inputMap
+ IdIndex produces effectively (int->int) map, but indexes API forces it to be (IdIndexEntry->Integer), which involves a lot of boxing. Try to optimize out some of these boxing by specialized IdEntryMapExternalizer

GitOrigin-RevId: d535c1bc8f9c3eb9878588df8b817d12bd6b3afa
2024-08-09 18:26:38 +00:00
Ruslan Cheremin
edb733a038 [indexes] refactor IdDataConsumer
+ extract explicit int->int map wrapper (IdEntryToScopeMapImpl), extract an IdEntryToScopeMap interface for it

GitOrigin-RevId: cd2cc114425121a945bdf82e3e0ff7a5769a52b4
2024-08-09 18:26:38 +00:00
Ruslan Cheremin
1388045ac4 [monitoring] allow customizing OTel metrics reporting periodicity
+ `-Didea.diagnostic.opentelemetry.metrics-reporting-period-ms=...`, with default=1 min (as before)

GitOrigin-RevId: 7220d207c555e458987d9e1d6e390f32bdca0fb4
2024-08-09 18:26:38 +00:00
Alexey Kudravtsev
9441e756d3 encapsulate TextEditorBackgroundHighlighter.getPasses, since it's dangerous and very implicit-contract-demanding
GitOrigin-RevId: cefb97e5a7798ad50e7bcc33da048f5e0e580ba3
2024-08-09 18:20:30 +00:00
Gregory.Shrago
3433a23e80 fix DataProvider cast in HighlightingOutputConsole
GitOrigin-RevId: 81ebd7113cdc071f8deb35e240f1609fca69702b
2024-08-09 18:18:23 +00:00
Gregory.Shrago
b54dcb3a6c fix DataProvider cast in lessons
GitOrigin-RevId: 7518e8c1d95c1bc1c269e152b1832e29f09180ee
2024-08-09 18:18:23 +00:00
Gregory.Shrago
9f9e26f421 fix DataProvider cast in LogConsoleBase
GitOrigin-RevId: 973bbcead9d5154fd6d40bcea56e2b339f7292b7
2024-08-09 18:18:23 +00:00
Gregory.Shrago
e3ea3aeb62 simplify SimpleDataContext initialization
GitOrigin-RevId: b6edcfb213008b427423e5315e619328a7d4660f
2024-08-09 18:18:23 +00:00
Frederik Haselmeier
5a08bed5cb [Kotlin] Explicitly enable K1/K2 compilers in KotlinCompilerReferenceTest and adapted tests
KTIJ-30927

GitOrigin-RevId: 09b56f04a5f87507881b551dd7ad5c4931addd04
2024-08-09 17:56:02 +00:00
Elena Shaverdova
36b77d69ab Five minutes for highlighting is long enough, and timeout is a great way to catch eternal highlighting
GitOrigin-RevId: 529765e27c6204ce5eb0770f1cc5363137fa9d84
2024-08-09 17:45:58 +00:00
Peter Gromov
ee614d7329 speed up PsiBuilderImpl during indexing: fewer checkCanceled calls, compare the text length only in debug mode
GitOrigin-RevId: d9c01cb740482b934c797672a81732ee19a51d93
2024-08-09 17:36:57 +00:00
Pavel Porvatov
881b0cee42 IJPL-156507 Make window controls side configurable in IDE
GitOrigin-RevId: 5a4a64ec42448c3caef516cfd2489ed002cda09a
2024-08-09 17:36:42 +00:00
Peter Gromov
6251753100 micro-optimize TrigramBuilder
cache isJavaIdentifier for ASCII characters
split array and CharSequence paths
specify some empirical initial capacity for the set
shorten the algorithm

GitOrigin-RevId: 43886096332ee00be145401a1d285dd41c66e852
2024-08-09 17:31:19 +00:00
Denis Zaichenko
2ffcbf1c24 IJPL-159911 Fixed the "OK" button in the "create patch" dialog. Added ability to overwrite the existing patch file.
GitOrigin-RevId: 8c630bf2cd7d326ca01feafdd5d5ef4a1922d503
2024-08-09 17:30:25 +00:00
Vladimir Kharitonov
533478aa7b IJPL-159336 JCEF: check sandbox enabled before checking apparmor restrictions
GitOrigin-RevId: 1d37f9f97a399a37308a33cb22bc626422579981
2024-08-09 17:27:34 +00:00
Vladimir Kharitonov
fe001b2b31 JBR-7429 JCEF: refactor: remove JBCefOsrHandlerBase
GitOrigin-RevId: a16a6ea8ed6f79a29ea0969eb48f6a8cd8e42d85
2024-08-09 17:27:34 +00:00
Vladimir Kharitonov
0994cb6ad2 JBR-7429 JCEF: refactor: remove unused code
GitOrigin-RevId: e9726b95e7e21b22fc647f9af6f73cb207f58706
2024-08-09 17:27:34 +00:00
Alexander.Glukhov
35ef00051e [IJPL-1050] added prefix for the repackaged jackson-core version property
GitOrigin-RevId: 54d5ad02333e6344136acad4b408214471ce3de3
2024-08-09 17:19:17 +00:00
Yuriy Artamonov
910e5e074f [icons] IJPL-159204 Default plugin icon is grey thus looks "disabled"
GitOrigin-RevId: 169288b4a50024af76f60f54ac507c492732e457
2024-08-09 17:18:08 +00:00
Roman Golyshev
7dcda70d69 KTIJ-27447 [kotlin] Do not optimize import in files which are not under content roots in K2 Mode
This can cause unexpected and undesired changes to the files which should
not be considered sources and cannot be properly analyzed (testdata, for example).
The import optimizer might kick in when such files are moved between
folders or renamed.

^KTIJ-27447 Fixed

GitOrigin-RevId: 3b80e63d500f3780fc33334b0f10f0a9ed9bedc7
2024-08-09 16:28:48 +00:00
Roman Shevchenko
026c9d84bf [devkit] checking SDK type in JUnitDevKitPatcher (EA-1014019)
GitOrigin-RevId: fe2e557e631773e07465fab4354f37b96ebb2304
2024-08-09 16:25:10 +00:00
Roman Shevchenko
5876a29bc9 [devkit] replacing multiple 'OpenedPackages.txt' error with a notification (EA-853559)
GitOrigin-RevId: b2754985a8200226026e0b4edbf2931466bbe186
2024-08-09 16:25:10 +00:00
Vladimir Lagunov
2793a56ddf IJent: unwrap IjentNioWslPath before passing to WindowsFSP
The bug was introduced in 276f56c4d08940f289657497bc1539dd24b21701 and caused problems like this:

```
java.nio.file.ProviderMismatchException
  at java.base/sun.nio.fs.WindowsPath.toWindowsPath(WindowsPath.java:389)
  at java.base/sun.nio.fs.WindowsFileSystemProvider.isSameFile(WindowsFileSystemProvider.java:434)
  at com.intellij.platform.core.nio.fs.DelegatingFileSystemProvider.isSameFile(DelegatingFileSystemProvider.java:200)
  at com.intellij.platform.core.nio.fs.DelegatingFileSystemProvider.isSameFile(DelegatingFileSystemProvider.java:200)
  at com.intellij.platform.ijent.community.impl.nio.telemetry.TracingFileSystemProvider.isSameFile(TracingFileSystemProvider.kt:73)
  at com.intellij.execution.wsl.ijent.nio.IjentWslNioFileSystemProvider.isSameFile(IjentWslNioFileSystemProvider.kt:190)
  at com.intellij.platform.core.nio.fs.DelegatingFileSystemProvider.isSameFile(DelegatingFileSystemProvider.java:200)
  at java.base/java.nio.file.Files.isSameFile(Files.java:1539)
  ...
```

GitOrigin-RevId: af9ea7cddd1768988bcfec9ba49e175ffa23fc99
2024-08-09 15:34:22 +00:00
Anna Kozlova
193d04914d Zero tolerance warning
GitOrigin-RevId: 2a76f336c414a73a9209cc8afab3af906487998f
2024-08-09 15:24:54 +00:00
Anna Kozlova
a01846c9c6 Zero tolerance warning
GitOrigin-RevId: c39a540915a990beced3f8461fafd04e4da9e4dc
2024-08-09 15:24:54 +00:00
Anna Kozlova
56cd217315 Zero tolerance warning
GitOrigin-RevId: 5d6e37cdfbebcc560e9698c52b82d95f4f524c0e
2024-08-09 15:24:54 +00:00
Anna Kozlova
524753d7c0 [kotlin] k2 change signature: add import if receiver is changed
- top level callables should be already imported
- member callables should be imported explicitly as their fqn is "replaced" with receiver

^KTIJ-30922 fixed

GitOrigin-RevId: 8c4c6319d5fac1a8e7930dbabdd67c3b1a4895b9
2024-08-09 15:24:54 +00:00
Bart van Helvert
86d0cc01ee [kotlin] Check read-only status in move refactoring
#KTIJ-28632 Fixed

GitOrigin-RevId: da90fc5f5e8ae910ddc2a311912bd7dd1e82f2e0
2024-08-09 15:12:41 +00:00
Eugene Morozov
578a61d592 [ui tests] OpenProjectInNewWindowUITest: Get second IDE frame by project name to fix flakiness
GitOrigin-RevId: c3af645294cf82f84a2f7efc240dac38de2c8a36
2024-08-09 14:58:51 +00:00
Dima Golovkov
ced10fdf2e Add icons for UX-3222
GitOrigin-RevId: 3c5dceac3c54b3f7bb8d77cf35e529bc6ba47451
2024-08-09 14:17:57 +00:00
Denis Zaichenko
befa1b7c22 [VCS] RCIIS fix import range when there is no import block.
IJ-MR-142077

GitOrigin-RevId: f6261822a88d1f1e18d6e057ff717d53805c4a70
2024-08-09 14:06:29 +00:00
Ruslan Cheremin
8c1fe60693 [indexes][comments] TODOs and rants
GitOrigin-RevId: b8ed38af85846f422f611cd6fb75e9bf6e39a24c
2024-08-09 14:05:38 +00:00
Ruslan Cheremin
9e32ecca88 [indexes][refactoring] move common .invalidateCachedMappings() method up to IndexStorage
+ added TODO about method name ambiguity

GitOrigin-RevId: cd07a47aae29a2f4e0a8a003f8af3cd9550ef457
2024-08-09 14:05:38 +00:00