Jinseong Jeon
6fc02c3408
SLC: ROOT package exists no matter what
...
^KT-59843 Fixed
2023-07-11 11:47:23 +02:00
Mikhail Glukhikh
71456c5514
FIR2IR: properly set constant expression type
2023-07-11 08:28:04 +00:00
Andrei Klunnyi
0bc3fc9203
KT-59801 [FIR] scripting: explicit import breaks reference shortening
...
FIR-tree for scripts is built either for KtScript or KtFile depending on
the file structure. The presence of import statements results in KtFile.
There are lazy trees (some nodes are stubs) that are not yet supported
for scripts. We build such ones for KtFile case.
This commit prevents lazy tree construction for scripts at references
shortening.
^KT-59801 fixed
2023-07-10 15:38:39 +02:00
Pavel Mikhailovskii
6e6a4d6411
KT-59836 [SLC] Copy type parameters from the parent interface to DefaultImpls methods
2023-07-10 13:11:21 +00:00
Andrei Klunnyi
a1385103bf
KT-60236 K2 scripting: completion fails with exception
...
^KT-60236 fixed
2023-07-10 14:37:16 +02:00
Andrei Klunnyi
527d20c7be
KT-60171 K2-scripting: CLI specific providers are used in IDE context
...
^KT-60171 fixed
Merge-request: KT-MR-10987
Merged-by: Andrei Klunnyi <andrei.klunnyi@jetbrains.com >
2023-07-10 11:03:11 +00:00
Nikolay Lunyak
79fce56c95
[FIR] Add a test for KT-59233
2023-07-10 10:26:43 +00:00
Nikolay Lunyak
4f0563dee1
[FIR] Add a test for KT-55933
2023-07-10 09:43:22 +00:00
Vladimir Dolzhenko
c1b70a7303
Move under debug log message when nested class is not found
...
To avoid freezes and useless reporting calculations
#KTIJ-25465 Fixed
Merge-request: KT-MR-10996
Merged-by: Vladimir Dolzhenko <Vladimir.Dolzhenko@jetbrains.com >
2023-07-08 07:18:09 +00:00
Yan Zhulanow
e5f9eb5b24
[LL API] Fix 'getResolvableSessionFor()' for library sessions
2023-07-07 13:34:01 +00:00
Bart van Helvert
362675a1b5
[AA] Support getting type from get and set annotation calls
...
#KTIJ-26206 Fixed
2023-07-07 12:57:45 +00:00
Dmitrii Gridin
6867dffff1
[LL FIR] rewrite on-air resolve
...
Now we will resolve declarations only ones and to the
minimal required phase to get a fully resolved element
depends on an insert position, because not all elements
require body resolution
A side change: `getOnAirGetTowerContextProvider` now
won't do rebind to the original declaration. In the future,
this part will be rewritten to avoid on-air resolution,
so it is not a problem
^KT-59685 Fixed
2023-07-07 11:42:22 +00:00
Brian Norman
61acd2b6f5
[FIR] Do not allow context receivers on value classes
...
#KT-59413 Fixed
2023-07-07 11:41:59 +00:00
Dmitriy Novozhilov
fc57f48c8f
[FIR] Union CFG edges from postponed lambdas only if outer call was analyzed independently
...
Before this change nodes unification was called if outer call was
completed in the FULL mode, but it may happen even if this call is
actually a part of some other outer call
2023-07-07 06:45:20 +00:00
Mikhail Glukhikh
15b070b494
K2: don't resolve callable reference to enum entries #KT-59611 Fixed
2023-07-06 15:06:31 +00:00
Yan Zhulanow
7e075ec64a
[FIR] Pass the whole body context to the resolve context collector
...
Collector for the 'FirCodeFragment' analysis needs to capture also
data-flow information.
2023-07-06 15:58:30 +09:00
Ilya Chernikov
70d2fcd9c4
K2 Scripting: deprecate top level script inner classes
...
no LT support yet
2023-07-05 19:46:03 +00:00
Dmitrii Gridin
83d0dbe436
[LL FIR] FileStructure: reanalyze declarations without name as well
...
^KT-60132 Fixed
^KT-59687
2023-07-05 20:29:01 +02:00
Dmitrii Gridin
9e88da2e66
[LL FIR] FileStructure: add tests for re-analyzable elements without names
...
^KT-60132
^KT-59687
2023-07-05 20:29:01 +02:00
Dmitrii Gridin
e354b2a900
[LL FIR] rewrote in-block modifications logic
...
Now we will invalidate bodies for FIR declarations
immediately after in-block modifications in these declarations
We assume that such in-block modifications can happen
only under write action,
so it should be safe to make changes for FirFile
^KT-59687 Fixed
^KT-59199 Fixed
^KTIJ-26066 Fixed
2023-07-05 20:29:00 +02:00
Dmitrii Gridin
a50efd7aa2
[LL FIR] treat changes inside contract description as OOBM
...
Because contracts affects resolution
^KT-59687
^KTIJ-26085 Fixed
^KTIJ-26066
2023-07-05 20:28:28 +02:00
Dmitrii Gridin
99e2a14b9c
[LL FIR] do not reanalyze non-top level properties with initializer
...
Treat changes inside non-top level property initializer as OOB
It is OOB because CFG for a class depends on a property initializer,
so we must rebuild CFG for the class
Also, this commit makes the API more understandable
^KT-59687
2023-07-05 20:28:28 +02:00
Dmitrii Gridin
8137bee09c
[LL FIR] drop empty files
2023-07-05 20:28:28 +02:00
Egor Kulikov
27f4b53570
[FIR] Do not expect builtin imports to be always resolved
...
Merge-request: KT-MR-10886
Merged-by: Egor Kulikov <Egor.Kulikov@jetbrains.com >
2023-07-05 14:02:50 +00:00
Mikhail Glukhikh
6bed02fed3
K2: fix an exception during function resolve #KT-59649 Fixed
2023-07-05 13:52:45 +00:00
aleksandrina-streltsova
116de97f54
[AA] Add synthetic properties scopes to scope context for position
2023-07-05 12:36:54 +00:00
Vladimir Dolzhenko
3c8c20f8d2
Do not do unnecessary writeBooleanAttribute
...
Merge-request: KT-MR-10945
Merged-by: Vladimir Dolzhenko <Vladimir.Dolzhenko@jetbrains.com >
2023-07-05 09:27:04 +00:00
Dmitriy Novozhilov
38533977f0
[Test] Add test for KT-35314
2023-07-05 06:56:15 +00:00
Dmitriy Novozhilov
5d6328a706
[Test] Add test for KT-53460
2023-07-05 06:56:15 +00:00
Dmitriy Novozhilov
31d046e8cd
[Test] Add test for KT-40851
2023-07-05 06:56:15 +00:00
Dmitriy Novozhilov
eb041d5d6d
[Test] Add test for KT-42995
2023-07-05 06:56:14 +00:00
Dmitriy Novozhilov
a35b3bfd17
[Test] Add test for KT-41198 and KT-59860
2023-07-05 06:56:13 +00:00
Dmitriy Novozhilov
2ad441f6c8
[Test] Add test for KT-47494
2023-07-05 06:56:13 +00:00
Dmitriy Novozhilov
03973419dd
[Test] Add test for KT-47892
2023-07-05 06:56:12 +00:00
Dmitriy Novozhilov
ca25610756
[Test] Add test for KT-47567
2023-07-05 06:56:11 +00:00
Anna Kozlova
142421da5b
[AA] support psi-resolve for loops labels
...
required for navigation, rename (KTIJ-25762), find usages.
Resolve through symbols can't work, because loops are not declarations
2023-07-04 17:37:49 +00:00
aleksandrina-streltsova
55a276705d
[AA] Shortener: extract visitor for kdoc collection to separate class
2023-07-04 16:34:53 +00:00
aleksandrina-streltsova
39bdd67df6
[AA] Shortener: change test data
...
Remove ON_AIR_CONTEXT_CARET_TAG where it's not necessary
2023-07-04 16:34:53 +00:00
aleksandrina-streltsova
d89aafb06c
[AA] Resolve package fqName in KDoc
2023-07-04 16:34:52 +00:00
aleksandrina-streltsova
9766270afa
[AA] Shorten kdocs that became available because of newly added imports
2023-07-04 16:34:52 +00:00
aleksandrina-streltsova
88f2bf85eb
[AA] Test shortener for the whole file with different options
2023-07-04 16:34:51 +00:00
aleksandrina-streltsova
67c3849538
[Analysis API] Shortener: enable shortening in KDoc
...
^KTIJ-21103
2023-07-04 16:34:51 +00:00
Kirill Rakhman
e7c213e06e
[FIR] Report separate error for delegated constructor call to interface
...
#KT-59216 Fixed
2023-07-04 16:00:45 +00:00
Kirill Rakhman
6d1d6e48c1
[FIR] Rename qualifiedAccessOrAssignmentsOrAnnotationCalls to callsOrAssignments and add delegated constructor calls
2023-07-04 16:00:45 +00:00
Dmitrii Gridin
09ca335b7e
[FIR] CFG: drop redundant edges
...
Edges from class to its functions and nested classes are redundant
and lead to extra resolution work in lazy resolve mode
^KT-59600 Fixed
2023-07-04 12:07:04 +00:00
Yan Zhulanow
df28bd1d79
[Stubs] Pass proper container source to stub-based FIR declarations
...
Backend, which is used by the expression evaluator, relies on the class
name in 'FacadeClassSource'. To pass the correct JVM class name,
stubs for top-level functions and properties got the 'origin'.
2023-07-04 11:17:39 +00:00
Yan Zhulanow
8bf8b7b35b
[LL API] Minor, prettify deserialized callable loading
2023-07-04 11:17:39 +00:00
Dmitrii Gridin
050c66ea81
[FIR] add missing Any super type to Cloneable
...
^KTIJ-24272 Fixed
2023-07-04 10:20:37 +00:00
Dmitrii Gridin
a81523fa74
[LL FIR] mark entire delegate as lazy expression
...
To simplify modification and restoring
^KT-59687
2023-07-04 10:09:51 +00:00
Denis.Zharkov
78e2d53f3c
K2: Adjust Analysis API to the recent scope structure changes
...
Namely, in the previous commit we merged two
(LOW and HIGH priority default start import scopes) into the single one
For more explanations, please look at the previous commit
2023-07-04 07:25:22 +00:00