Mikhael Bogdanov
328160894b
Move ir.tree.impl into ir.tree
2022-06-20 11:42:51 +00:00
Evgeniy.Zhelenskiy
28bf83ceac
[IR] Unite inline class and multi-field value class representation
...
#KT-1179
2022-03-24 11:38:43 +00:00
Evgeniy.Zhelenskiy
282ab398c6
[IR] Generify lowerings
...
#KT-1179
2022-03-24 11:38:42 +00:00
Dmitry Petrov
7f95d7f414
IR make 'name' a var
2022-02-18 15:37:42 +00:00
Evgeniy.Zhelenskiy
e97ca2ada4
[Psi2Ir, Fir2Ir] Generate toString, hashCode, equals methods for MF VC
2022-01-14 13:51:57 +00:00
Vyacheslav Gerasimov
f7a9065b75
Build: Use intellij maven repo instead of downloaded IDEA
...
#KTI-82
2021-12-16 21:48:23 +03:00
Ilya Chernikov
cb5e451e05
Implement script instance capturing in script lowering
...
for regular classes only. Reimplementing the main behavior of the
old BE and implementing few cases on top of it.
#KT-19423 fixed
2021-12-14 13:39:17 +03:00
Anton Bannykh
4de69fb4b5
[JS IR] store signatures for private symbols separately from public
...
Those signatures are used in JS IR IC
2021-12-03 12:58:24 +03:00
Anastasiya Shadrina
d0794e6741
[IR] Make contextReceiverParametersCount abstract in IrFunction
2021-12-02 20:24:34 +03:00
Anton Bannykh
56e1c4e38f
[JS IR] IrFactory which saves signatures for declarations created in BE
2021-11-19 00:39:12 +03:00
Dmitry Petrov
146f0f4904
JVM_IR KT-41214 emit PermittedSubclasses on JDK17+
2021-10-09 17:07:35 +03:00
Vyacheslav Gerasimov
ab146bd6d4
Build: Fix deprecated Gradle configurations usages
...
for migration to Gradle 7+ #KTI-559
2021-09-26 18:28:44 +03:00
Anton Bannykh
76f0684d7c
IR: .isBound API for F/O declarations
...
Fake override functions and properties may not be bound to symbols.
This API allows to know if such declaration is actually bound
2021-07-22 21:56:47 +03:00
Georgy Bronnikov
6b80c00cc6
JVM_IR: deserialize lazy declarations
2021-07-14 21:20:14 +03:00
Dmitry Petrov
53c1de172f
IR KT-46578 add IrProperty#overriddenSymbols
2021-05-14 16:20:18 +03:00
Alexander Udalov
54befa769f
IR: add IrClass.getInlineClassRepresentation, serialize/deserialize it
...
The change in FirDeclarationUtil is needed because in case of unsigned
types loaded from the standard library, the primary constructor for some
reason is not the first, but the second in the list of constructors.
2021-05-13 13:56:59 +02:00
Alexander Udalov
99e022d023
IR: minor, remove duplicate visibility field
2021-04-22 17:42:18 +02:00
Anton Bannykh
87f3ca3f36
IR: make isExternal immutable
2021-03-02 14:30:18 +03:00
Anton Bannykh
c06b345f3c
Hide stageController into the IrFactory
2021-02-17 10:42:50 +03:00
Svyatoslav Kuzmich
2a424ad2af
[IR] Make isExternal mutable and accessible via common interface
...
JS IR: Mark all effectively external declarations as external to access it
directly instead of computing it every time
2021-02-04 16:15:33 +03:00
Georgy Bronnikov
c5961da780
IR: remove WrappedDescriptors altogether
2020-12-23 18:50:52 +03:00
Georgy Bronnikov
b07dccb8d7
Fir2IR: remove wrapped descriptors
2020-12-23 18:50:52 +03:00
Georgy Bronnikov
d714adacae
IR: removing WrappedDescriptors from symbols
2020-12-23 18:50:51 +03:00
Mads Ager
5d9e86863a
[IR] Make isHidden and isAssignable explicit on IrValueParameter.
...
There were a couple of places where they were confused and
isAssignable was passed as a positional parameter in the position
of isHidden.
2020-12-04 17:04:45 +01:00
Zalim Bashorov
2c1e4c1769
[IR] Use more specific type (IrSimpleFunction) for accessors in IrLocalDelegatedProperty
2020-11-05 22:25:05 +03:00
Mads Ager
1f2ca606a5
[IR] Add isAssignable property to IrValueParameter.
...
Use it to check that only the value parameters that are explicitly
marked assignable are assigned.
Currently, the only parameters marked assignable are those for
default argument stubs.
2020-10-06 21:47:29 +02:00
Dmitry Petrov
b1bd138afb
JVM_IR fix inline class <-> collection stubs issues
...
Move collectionStubMethodLowering before jvmInlineClassPhase, and make
them interact properly.
Note that some issues still remain in inline class <-> special bridges
interaction.
KT-40187 KT-42469
2020-10-06 17:08:24 +03:00
Alexander Udalov
2573eaa77f
IR: do not crash renderer on functions with uninitialized return type
...
This is a follow-up to b497f39c29 . It
turns out that it didn't help because `IrFunction.returnType` throws
exception, and checking for `IrUninitializedType` in `IrType.render` was
already too late. Throw and catch specific exception instead.
Also add function name into the exception message for better diagnostics
elsewhere (can't compute the full FQ name because in cases like
KT-42020, the parent is also uninitialized).
2020-10-06 14:23:34 +02:00
Alexander Udalov
06f1bd6101
Reformat IR tree declarations and implementations
...
Most of the changes are to the incorrect formatting introduced in
d1fd1da56f .
2020-10-06 14:21:40 +02:00
Georgy Bronnikov
df1d9a0113
IR: make IrTypeParameter.superTypes persistent mutable field
2020-09-22 23:53:39 +03:00
Georgy Bronnikov
a409976d28
IR: make IrValueParameter.varargElementType mutable
2020-09-22 23:53:39 +03:00
Georgy Bronnikov
a3763e8276
IR: make IrTypeAlias.expandedType mutable
2020-09-22 23:53:39 +03:00
Georgy Bronnikov
78fc690f29
IR: make IrLocaldelegatedProperty.type mutable
2020-09-22 23:53:39 +03:00
Georgy Bronnikov
d9681e535d
IR: make IrField.type mutable
2020-09-22 23:53:39 +03:00
Georgy Bronnikov
5065b1a4c6
Make IrValueDeclaration.type mutable
2020-09-22 23:53:38 +03:00
Roman Artemev
f01941d1dd
[IR] Support isHidden is IrFactory API
...
- add API to create a hidden value parameter
2020-09-17 00:57:16 +03:00
Roman Artemev
79e2886da1
[IR] Add isHidden flag into IrValueParameter
2020-09-17 00:57:15 +03:00
Dmitriy Novozhilov
d1fd1da56f
Rename Visibility to DescriptorVisibility
2020-09-04 11:07:42 +03:00
Alexander Udalov
9d81e50128
IR: undeprecate IrUninitializedType
...
It's no longer a temporary hack, see the comment.
2020-08-27 18:02:04 +02:00
Alexander Udalov
08a35f0674
IR: make IrBody and subtypes classes
2020-08-11 14:41:57 +02:00
Alexander Udalov
e3dfd5fb49
IR: push down implementations of startOffset/endOffset/type/...
...
Do not store these as properties in IrElementBase, IrExpressionBase and
similar classes. This helps to reduce boilerplate in implementations
(just "override val" in the constructor, instead of taking a parameter
and passing it to the superclass), and also slightly optimizes memory in
cases where the value is trivial (UNDEFINED_OFFSET, 0, etc) and thus
does not need to be stored.
2020-08-11 14:41:54 +02:00
Georgy Bronnikov
dafcdc527d
IR: propagate original declaration info via attributeOwnerId
...
For IrProperty, IrSimpleFunction we need to pass information about
original declaration to JVM_IR codegen. Instead of descriptors, use
the attributeOwnerId field.
2020-08-10 10:16:23 +03:00
Georgy Bronnikov
04d93dfbce
IR: move containerSource from descriptor to IrFunction, IrProperty
2020-08-10 10:16:23 +03:00
Alexander Udalov
771e7574f4
IR: make subtypes of IrDeclaration classes
2020-08-06 17:08:03 +02:00
Alexander Udalov
b02653a524
IR: remove base classes IrDeclarationBase and IrFunctionBase
...
They introduce a diamond class hierarchy which prevents IR element
hierarchy from being transformed to classes.
2020-08-06 16:46:26 +02:00
Alexander Udalov
f240d51d2c
IR: do not inherit IrFakeOverride* from IrFunction/IrProperty
...
This will help to reduce boilerplate after making the latter classes.
Without this change, IrFunctionCommonImpl would not be able to be a
class because it would introduce a diamond class hierarchy, and thus
that would require copying all its contents to IrFunctionImpl and
IrFakeOverrideFunctionImpl.
2020-07-28 19:05:12 +02:00
Alexander Udalov
cce55f1609
IR: add module ir.tree.impl, move main IR implementation there
2020-07-28 19:04:44 +02:00