Dmitriy Novozhilov
d66748d011
[FIR] Extract expect actual matching into separate phase
2022-05-20 13:33:04 +00:00
Denis.Zharkov
853b7ec078
FIR: Use NullableAny as a default bound
2022-05-19 16:53:58 +00:00
Ivan Kylchik
a993939127
[FIR] Allow constant values for IntrinsicConstEvaluation declarations
2022-05-18 21:19:55 +03:00
Denis.Zharkov
b87412c5af
FIR2IR: Fix substitution work for context receivers
2022-05-13 18:04:02 +00:00
Denis.Zharkov
299c02a822
FIR: Introduce FirContextReceiverArgumentListOwner
...
Add it as a supertype for FirQualifiedAccess and FirDelegatedConstructorCall
^KT-51889 Related
2022-05-13 18:04:01 +00:00
Ilya Kirillov
6e0eba7e00
[low level api] fix ISE: Expected FirResolvedTypeRef with ConeKotlinType but was FirImplicitTypeRefImpl for CheckDslScopeViolation
2022-05-11 13:14:44 +02:00
Victor Petukhov
47d6236a2d
[FIR] Support determining emptiness of an intersection type with type parameters' types
2022-04-27 19:50:23 +00:00
Ivan Kochurkin
8c7fad9a5e
[FIR] Support of type arguments in annotations ^KT-48444 Fixed
2022-04-18 15:36:19 +00:00
Jerome Prinet
44b2905800
Fix JavaApplication.setMainClassName deprecation
2022-04-14 14:21:31 +03:00
Jerome Prinet
6aec88446a
Fix JavaExec.main deprecation
2022-04-14 14:21:31 +03:00
Jinseong Jeon
2763b58cdd
RAW FIR: use special name for default setter parameter
...
FE1.0 descpritor, PSI2IR, and JVM IR backend use that.
FIR2IR is also using that, which implies name "value" in RAW FIR
maybe has not been used anywhere.
2022-04-12 22:05:22 +02:00
Denis.Zharkov
ac399321f0
FIR: Add replace method for contextReceiverNumber
2022-04-06 16:05:37 +00:00
Denis.Zharkov
c33f06b9e4
FIR tree: add context receivers helper properties
2022-04-06 16:05:34 +00:00
Denis.Zharkov
ef84dddc88
FIR: Add preliminary support for context receivers in resolution
2022-04-06 16:05:32 +00:00
Denis.Zharkov
90b12433ec
FIR: Add replaceContextReceivers to FirCallableDeclaration
2022-04-06 16:05:31 +00:00
Denis.Zharkov
c595780d83
FIR: Add two label-related fields to FirContextReceiver
2022-04-06 16:05:26 +00:00
Denis.Zharkov
550d24f8c6
FIR: Introduce ContextFunctionTypeParams type attribute
2022-04-06 16:05:26 +00:00
Denis.Zharkov
54c3e7e7c5
FIR: Support context receiver in FIR building
2022-04-06 16:05:24 +00:00
Denis.Zharkov
a89680fb34
FIR: Prepare tree for context receivers
2022-04-06 16:05:23 +00:00
Dmitriy Novozhilov
5a3b397552
[FIR] Get rid of FirTypedDeclaration
...
`FirTypedDeclaration` has only one inheritor (`FirCallableDeclaration`),
so there is no much sense to keep this class
2022-04-04 15:23:58 +00:00
Ilya Chernikov
5d6e2b57a7
Sort sealed class inheritors to ensure reproducible builds with IC
...
without this sorting the inheritors field in the metadata may depend on
whether some inheritors are compiled in the IC round or not.
2022-03-30 08:35:30 +00:00
Ilya Chernikov
03cbfea737
FIR LT: Introduce source file abstraction, carry it from parsing to IR
...
along with source lines mapping, allows to "emulate" usage of the
PSI files which allows to extract source file and line mapping info
on every stage from source element.
It makes sense to use this mapping for the error reporting too.
2022-03-30 08:34:30 +00:00
Evgeniy.Zhelenskiy
b6f2513dd2
[FIR] Introduce valueClassRepresentation to FIR
...
#KT-1179
2022-03-24 11:38:44 +00:00
Mikhail Glukhikh
87a7408ddf
FIR: handle double-imported qualifiers properly
2022-03-15 13:21:02 +00:00
Ilya Chernikov
6ae55a98cd
FIR2IR: fix annotations conversion for precompiled functions
...
fixes the case then the function being inlined is taken
from the binaries compiled on the previous iteration, and therefore
should be treated similarly to a fun from a library.
2022-03-14 13:37:50 +03:00
Dmitriy Novozhilov
ade2307345
[FIR] Fix exponential analysis of augmented array access calls
...
^KT-50861 Fixed
2022-03-11 15:36:05 +03:00
Mikhail Glukhikh
34998473f5
FIR: Move deprecation resolve earlier
2022-03-10 20:42:41 +00:00
Mikhail Glukhikh
30fa0230ec
FIR: rename ANNOTATION_FOR_PLUGINS into COMPILER_REQUIRED_ANNOTATIONS
2022-03-10 20:42:40 +00:00
Mikhail Glukhikh
9aaf7b7d24
FIR: drop pluginPhase special parameter
2022-03-10 20:42:40 +00:00
Dmitriy Novozhilov
18fc2802e5
[FIR] Make FirTypeParameter.containingDeclarationSymbol not null
...
Also fix initializing this property in all places
2022-02-28 11:42:34 +03:00
Jinseong Jeon
790f2d13ae
RAW FIR: record non-null value parameter of Enum#valueOf upfront
2022-02-24 17:51:50 +01:00
Jinseong Jeon
2599c1dbb6
FIR: use StandardNames (instead of hardcoded constants)
2022-02-24 17:51:48 +01:00
Simon Ogorodnik
857fe985b2
FIR tree. Make intersection type part-types non-null
2022-02-21 12:23:25 +00:00
Dmitriy Novozhilov
23af5510a6
[FIR] Render full declaration header in diagnostic messages
2022-02-18 17:44:38 +03:00
Alexander Udalov
480c15277d
FIR tree gen: extract interface/class solver to generators
2022-02-17 00:32:44 +01:00
Alexander Udalov
db1d1be4fc
FIR tree gen: refactor interface/class solver code
...
To be able to reuse it in the upcoming IR tree generator.
2022-02-17 00:32:44 +01:00
Dmitriy Novozhilov
52b72a7dac
[FIR] Implement Int -> Long conversions for literals and operators over them
...
^KT-38895
^KT-50996 Fixed
^KT-51000 Fixed
^KT-51003 Fixed
^KT-51018 Fixed
2022-02-07 13:36:36 +03:00
Dmitriy Novozhilov
b980f5ab32
[FIR] Introduce new kind of integer literal types for constant operator calls
2022-02-07 13:36:35 +03:00
Dmitriy Novozhilov
bb5217be72
[FIR] Don't create ILT for integer literal if its value don't fit to Int type
2022-02-07 13:36:34 +03:00
Dmitriy Novozhilov
0bd3e8f418
[FIR] Rename ConeClassErrorType to ConeErrorType, drop ConeKotlinErrorType alias
2022-02-07 13:36:33 +03:00
Dmitriy Novozhilov
84913772ec
[FIR] Drop redundant FirIntegerOperatorCall and number of fir copy methods
2022-02-07 13:36:32 +03:00
Roman Golyshev
aabd5d98bb
[FIR] Fix confused metaUnder and metaHas
2022-02-06 15:29:52 +03:00
Mikhael Bogdanov
15e08893aa
FIR: support DefinitelyNotNull types
...
#KT-49465 Fixed
2022-02-03 14:07:20 +01:00
Denis.Zharkov
adb9dfb256
FIR: Rework processing AugmentedArraySetCall
...
Previously (few commits earlier), it contained two versions
of receiver (lhs) generated separately for each desugaring version
that looked a bit redundant.
Now, at FIR building stage we just don't create desugaring sub-trees,
instead they are being built during bodies transformation and that seems
to be much convenient there, since we don't need to reverse-engineer
get-set-operator version to check if containing calls are successful
(as we just built those calls and retain them)
Semantically, this changes may only change how data flow works
for such statements (see changed compatibilityResolveWithVarargAndOperatorCall.kt)
^KT-50861 Relates
2022-02-01 13:12:49 +03:00
Denis.Zharkov
6f89f1ebf4
FIR: Allow selector of safe calls to be a FirStatement
...
It's necessary to allow a?.b += v be interpreted as a?.(b += v)
But currently FirAssignmentOperatorStatement is not FirQualifiedAccess
^KT-41034 In Progress
2022-02-01 13:12:45 +03:00
Ilya Kirillov
16fbc09997
Analysis API: use FirSymbol in KtFirSymbol's instead of FirDeclaration
...
^KT-50271 fixed
2022-01-21 16:46:27 +01:00
Ilya Kirillov
b20859e305
FIR: use "value" name in default setter value parameter symbol
...
This name is used in corresponding declaration
2022-01-21 16:46:26 +01:00
Ilya Kirillov
ce1e4f252f
FIR: make transformInplace to be thread safe if no transformation was done
...
^KT-50822 fixed
2022-01-20 23:28:08 +03:00
Dmitriy Novozhilov
c80cfb0fdb
[FIR] Replace single supertype scope with list of scopes of supertypes in use site scopes
...
This big refactoring is needed to cleanup building of overrides
mappings and prevent creating redundant intersection overrides in
cases when there is no need in them:
```kotlin
interface A {
fun foo()
}
interface B {
fun foo()
}
interface C : A, B {
override fun foo()
}
```
Before this refactoring there was next override tree:
C.foo
intersection override (A.foo, B.foo)
A.foo
B.foo
Also this commit fixes special mapping of overrides in jvm scopes
for declarations which have kotlin builtins in supertypes with
special java mapping rules (collections, for example)
2022-01-19 15:24:43 +03:00
Dmitriy Novozhilov
d588b2e654
[FIR] Add toString to all type scopes
2022-01-19 15:24:43 +03:00