Georgy Bronnikov
49576e0cbb
Fir2Ir: handle nested class references in type parameter bounds
2022-05-19 12:02:44 +02:00
Georgy Bronnikov
9fb1a901cf
Fir2Ir: handle intersection types in FirJvmMangleComputer
2022-05-19 12:02:44 +02:00
Georgy Bronnikov
12533a383e
JVM_IR: mute tests for compiling against Klib
...
The tests fail currently because Klibs are generated by the JS backend,
and signatures differ between JVM and JS (on JVM, return types are
included in mangles for simple functions).
This leads to linkage errors.
Once signatures are reworked and harmonized between backends, the tests
will repair themselves.
2022-05-19 12:02:44 +02:00
Georgy Bronnikov
a8cc3ec316
Fir2IR: introduce IdSignature?.iscomposite()
2022-05-19 12:02:44 +02:00
Georgy Bronnikov
64818c817f
Fir2Ir: do generate enum constructors even when private
2022-05-19 12:02:43 +02:00
Georgy Bronnikov
32e94cc126
Fir2Ir: simplify check for fake override in createIrLazyFunction
2022-05-19 12:02:43 +02:00
Georgy Bronnikov
d2781f37ad
Fir2Ir: ignore private imported declarations
...
Code that checks for inclusion is translated from IrLazyClass.
2022-05-19 12:02:43 +02:00
Georgy Bronnikov
536bd99fe7
Fir2Ir: use class id when determining whether declaration is toplevel
2022-05-19 12:02:43 +02:00
Georgy Bronnikov
39bba7973c
Fir2Ir: create file level signatures where appropriate
...
This is godugly code, where a flag for file level signatures is passsed
around.
An alternative would be not to create file level signatures for toplevel
private clases, since those still need unique names, at least on JVM.
But that would break binary compatibility.
Signatures are due for overhaul anyway. Hopefully this code can be
reverted at that point.
2022-05-19 12:02:43 +02:00
Georgy Bronnikov
9d4ab09b41
FIR: mute test
...
Getters for synthetic Java properties are generated as substituted
declarations, which leads to wrong bytecode.
2022-05-19 12:02:43 +02:00
Georgy Bronnikov
dafcafc232
Fix infinite tail recursion
2022-05-19 12:02:43 +02:00
Georgy Bronnikov
870ee9c445
Fir2Ir: mute a test
...
FIR computes return type of testGeneric1 as T (type parameter).
Looks like a FIR bug.
2022-05-19 12:02:43 +02:00
Georgy Bronnikov
12818823b0
Fir2Ir: test data
2022-05-19 12:02:43 +02:00
Georgy Bronnikov
1eaec5a6e6
Fir2Ir: use typeContext in Fir2IrDeclarationStorage.createIrParameter
2022-05-19 12:02:43 +02:00
Georgy Bronnikov
109bdb9572
Adjust tests for FirSerializeCompileKotlinAgainstKotlin
2022-05-19 12:02:43 +02:00
Georgy Bronnikov
e7b1cc03de
Fir2Ir: deal with flexible and raw types in FirJvmMangleComputer and type converter
2022-05-19 12:02:43 +02:00
Georgy Bronnikov
ad625a4631
Fir2Ir: deal with Java fields in FirIrProvider
2022-05-19 12:02:43 +02:00
Georgy Bronnikov
5605463ecf
Introduce IGNORE_BACKEND_FIR_MULTI_MODULE directive
2022-05-19 12:02:43 +02:00
Georgy Bronnikov
571ba9298e
Fir2Ir: put properties data from IrBuiltinsOverFir into symbol table
...
Properties themselves, accessors, backing fields.
2022-05-19 12:02:43 +02:00
Georgy Bronnikov
12b2828499
Remove diagnostic check from second module in SplittingModuleTransformerForBoxTests
2022-05-19 12:02:42 +02:00
Georgy Bronnikov
ff2f6fe5e5
Fir2Ir: handle enum entries in Fir2IrProvider
...
NB: only the easy path works for sure. Need to have a look at:
- enum entry members
- Java enum entries
2022-05-19 12:02:42 +02:00
Georgy Bronnikov
0653ba7313
Fir2Ir: Specify containingClass in getOrCreateIrFunction
2022-05-19 12:02:42 +02:00
Georgy Bronnikov
bbec6f0d85
Fir2Ir: handle type parameter signatures
...
Type parameter references should be deserialized.
2022-05-19 12:02:42 +02:00
Georgy Bronnikov
a6d4cd0fe4
Fir2Ir: compute mangles for anonymous objects
...
Needs review to avoid assigning the same mangle to different objects,
2022-05-19 12:02:42 +02:00
Georgy Bronnikov
12d34589d8
Psi2Ir, Fir2Ir: always include return type into signature mangle of a function
2022-05-19 12:02:42 +02:00
Georgy Bronnikov
b79903b2f4
Fir2Ir: do generate signatures for private declarations
2022-05-19 12:02:42 +02:00
Georgy Bronnikov
a251a49664
Fir2Ir: register special annotations in symbol table
2022-05-19 12:02:42 +02:00
Georgy Bronnikov
6421e649ad
Fir2Ir: fix mangling property type parameters for accessor signatures
2022-05-19 12:02:42 +02:00
Georgy Bronnikov
1c00f731fd
Fir2Ir: deal with fake overrides in FirIrLinker
2022-05-19 12:02:42 +02:00
Georgy Bronnikov
0ef474a8d3
Do not set parent for deserialized IR declarations
2022-05-19 12:02:42 +02:00
Georgy Bronnikov
49bd3c1758
Fir2Ir: make sure Fir2IrLazyClass gets registered in symbol table
2022-05-19 12:02:42 +02:00
Georgy Bronnikov
1fbd79e310
Fir2Ir: fix deserializing IR for property accessors
...
1. Need to register Fir2IrLazyPropertyAccessors in symbol table.
2. Need to set their bodies.
2022-05-19 12:02:42 +02:00
Georgy Bronnikov
f94b0bbcea
Fir2Ir: add Fir2IrTypeParametersContainer
...
Fir2IrLazyProperty should not be a IrTypeParametersContainer.
2022-05-19 12:02:42 +02:00
Georgy Bronnikov
4b34648327
Fir2Ir: repair computation of IR signatures
2022-05-19 12:02:42 +02:00
Georgy Bronnikov
ffe1615e9c
Fir: simplify IrBuiltInsOverFir
2022-05-19 12:02:42 +02:00
Georgy Bronnikov
bf5cd14acd
Fir2Ir: allow setting Fir2IrLazyConstructor.extensionReceiverParameter
...
Needed by handleJvmStaticInSingletonObjects after IR deserialization.
2022-05-19 12:02:42 +02:00
Georgy Bronnikov
8771ce94ef
Fir2Ir: deal with toplevel privates
2022-05-19 12:02:41 +02:00
Georgy Bronnikov
9ea14a6eab
Fir2Ir: pass file data to Fir2IrSignatureComposer
2022-05-19 12:02:41 +02:00
Georgy Bronnikov
ae158e4c5b
Fir2Ir: make Fir2IrLazyClass a DeserializableClass
2022-05-19 12:02:41 +02:00
Georgy Bronnikov
0012ba79e1
Fir2Ir: rework FirIrProvider
2022-05-19 12:02:41 +02:00
Georgy Bronnikov
4a450a6627
Fir2Ir: handle flexible types in FirJvmMangleComputer
...
This is preliminary: like Fir2IrTypeConverter, we just take the upper
bound. Need to replicate the approximation performed in TypeTranslator.
2022-05-19 12:02:41 +02:00
Georgy Bronnikov
57679bda79
Fir2Ir: run type enhancement in FirIrProvider
2022-05-19 12:02:41 +02:00
Georgy Bronnikov
829b2822c6
Fir2Ir: adjust FirBasedSignatureComposer for constructors
...
Consatructor's name in the signature should be '<init>', not the
name of the constructed class.
2022-05-19 12:02:41 +02:00
Georgy Bronnikov
af123d1daf
Fir2Ir: deserialize bodies of inline functions
2022-05-19 12:02:41 +02:00
Georgy Bronnikov
e0c175bb50
Fir2Ir: remove symbolTable as separate component from FirResult
...
It's already in components.
2022-05-19 12:02:41 +02:00
Georgy Bronnikov
3f66b31a47
Fir2Ir: add irProviders to Fir2IrComponents
...
Removes the last use of DeclarationStubGenerator in the FIR pipeline.
2022-05-19 12:02:41 +02:00
Georgy Bronnikov
13d4d60afa
Fir2Ir: pass Fir2IrExtensions to backend
2022-05-19 12:02:41 +02:00
Georgy Bronnikov
3c3c1be543
Fir2Ir: introduce Fir2IrExtensions
...
This allows us to remove DeclarationStubGenerator from Fir2IrConverter,
thus reducing dependency on descriptor-based code.
2022-05-19 12:02:41 +02:00
Georgy Bronnikov
6bc01f031c
JVM_IR: remove dependency of JvmFileFacadeClass on stub generator
2022-05-19 12:02:41 +02:00
Georgy Bronnikov
3c939a1bdd
Fir2Ir: remove unneeded ExternalDependenciesGenerator calls
2022-05-19 12:02:41 +02:00