mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-02-04 23:39:07 +07:00
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