Irene Dea
f2a351367c
Implement unionTypeAttributes and replaceTypeAttributes in ConeInferenceContext
2022-01-08 15:25:07 +03:00
Irene Dea
56d817b49f
Union type attributes for common super type calculation
2022-01-08 15:25:07 +03:00
Irene Dea
fad3c1f2f6
Add initial type attributes infra
2022-01-08 15:25:06 +03:00
Irene Dea
62bde2d686
Move AttributeArray to compiler.common so frontend extension can share it
2022-01-08 15:25:06 +03:00
Igor Yakovlev
82455c849d
[WASM] Lazy properties initialization
2022-01-05 13:12:32 +01:00
Igor Yakovlev
e58d4163ad
[WASM] Add std methods for collections
2022-01-05 13:12:32 +01:00
Igor Yakovlev
adee0f1cb0
[WASM] Add kotlin.math implementation
2022-01-05 13:12:32 +01:00
Igor Laevsky
cfcbe9e1e2
[Wasm] Better preserve IR types after inlining
2022-01-01 20:04:44 +02:00
Xin Wang
9ae452e489
JVM_IR generate less bytecode for for-loops if possible(KT-22334).
2021-12-31 18:29:04 +03:00
Dmitry Petrov
3b928e1780
JVM_IR move increment intrinsic handling to JvmOptimizationLowering
2021-12-31 05:37:40 +00:00
Dmitry Petrov
bcec952beb
JVM_IR KT-50585 array constructor loop should end with IINC
2021-12-30 21:38:58 +03:00
Kristoffer Andersen
27a2d7f614
[IR] Generalize fragment generation logic for wider use
...
Generalize the config specific to evaluator fragment compilation for wider
applicability.
2021-12-30 12:10:54 +01:00
Dmitry Petrov
1e5fc1c3aa
JVM_IR KT-27427 use checkNotNull with message in checked casts
...
This would prevent extra branching in 'as <not-null-type>', which
usually would not be covered.
2021-12-30 13:41:21 +03:00
Dmitry Petrov
9132c9b2d0
JVM don't choke on exceptions in ClassFileFactory#createText
2021-12-30 13:41:19 +03:00
Dmitry Petrov
4ad6cfcf53
JVM_IR fix cast to not-null type
...
We can't rely on argument type nullability here, because it still can
hold an uninitialized value on JVM.
KT-50577 KT-35272 KT-27427
2021-12-30 13:41:17 +03:00
Alexander Korepanov
4a29a8a7af
[JS IR] Update an error on cross-module symbol redeclaration
...
The temporary solution for KT-50546.
The complete solution requires the understanding,
whether a cross-module symbol redeclaration is a valid case or not.
If the case is valid, the linker symbol table logic must be reworked.
2021-12-30 08:44:11 +00:00
Jinseong Jeon
a153a1fefb
FIR LC: create inline methods
...
unless the functions (or accessors) have reified type parameters
or inline-only annotations
2021-12-30 10:47:32 +03:00
Alexander Udalov
d5372521f1
Add tests for obsolete issues
...
#KT-12126
#KT-12189
#KT-23628
#KT-24209
#KT-34338
#KT-47279
#KT-48498
2021-12-29 17:07:03 +00:00
Dmitry Petrov
5946242d75
JVM_IR fix special bridges in mixed Java/Kotlin hierarchies
...
KT-50257 KT-50476
2021-12-29 13:29:19 +00:00
Ivan Kylchik
493d9a49cb
Drop jmh benchmarks for light-tree2fir
...
These benchmarks are not used and interfere with FIR IDE plugin.
2021-12-29 16:23:12 +03:00
Anton Bannykh
1b631da3a0
[JS IC] fix cross-module nested class references and interface inheritance
...
^ KT-50528 fixed
2021-12-29 16:04:06 +03:00
Ivan Kylchik
6fc56477bf
Drop all tests that disable features for language version less than 3
2021-12-28 20:08:56 +03:00
Ilmir Usmanov
549ea1a3b9
If fun interface methods are already mangled, do not mangle them twice
...
There are two possible scenarios, when fun interface method with inline
class parameter can be compiled.
First is when we compile fun interface itself before SAM adapter. In
that case, fun interface is lowered before we lower SAM adapter. Thus,
its method is mangled and mangling in the second time is an error.
Second is when we compile SAM adapter before the fun interface. In that
case, fun interface is not lowered, and we have to mangle the method.
The only way to distinguish there two cases I can think of is to check
whether the overridden method is already mangled, in other words, check,
whether the overridden method's suffix is doubled.
#KT-48499: Fixed
2021-12-28 17:35:12 +01:00
Alexander Udalov
9a9a8f1999
Restore support of language version 1.3
...
#KT-50251 Fixed
(cherry picked from commit a0004ed03adc9f50f26c8b11d178afcc2abf2a9c)
2021-12-28 13:21:18 +01:00
Alexander Udalov
92c80873ba
Revert "JVM: remove support for disabling NoConstantValueAttributeForNonConstVals"
...
This is a partial revert of e857966edb .
Specifically, behavior is restored in the old backend, which will allow
to support language version 1.3, where this language feature was not
enabled yet. There are no changes in the JVM IR backend, because to
enable JVM IR with LV 1.3, you need to pass the compiler argument
`-Xuse-ir` which is not stable and we don't guarantee anything about it.
#KT-50251
2021-12-28 13:21:18 +01:00
Roman Artemev
723ef8f1fb
[KLIB] Deserialize backing field initializers of const in IB-only mode
...
Missing const initializer leads to crash in property accessors inline
lowering during IC recompilation on JS.
- fix #KT-50512
- add test for JS IR IC
2021-12-27 23:43:43 +03:00
Victor Petukhov
29f174f074
Revert "Revert "Temporary workaround for failing tests on teamcity.""
...
This reverts commit 2c51799e0a .
2021-12-27 22:56:01 +03:00
Victor Petukhov
9c225c5b56
Revert "[Compiler CLI] Use LanguageVersion.LATEST_STABLE instead of KotlinVersion.CURRENT for java type enhancement settings to prevent dependency on kotlin version."
...
This reverts commit 0689d74353 .
2021-12-27 22:56:00 +03:00
Ilya Kirillov
62c9a7888b
Analysis: remove // FIR_COMPARISON form LC testdata as LC tests are moved from IJ
2021-12-27 16:23:21 +03:00
Ilya Kirillov
4e58dc3467
Fix small compilation problems in LC testdata which should not influence LC results
2021-12-27 16:23:21 +03:00
Ilya Kirillov
02f9f116b2
Analysis: ignore failing LC test
2021-12-27 16:23:20 +03:00
Ilya Kirillov
db31e0292c
Analysis: add LC testdata with current behaviour
2021-12-27 16:23:20 +03:00
Ilya Kirillov
0b3a0fd799
Analysis: fix LC test environment
2021-12-27 16:23:19 +03:00
Ilya Kirillov
40fdb26569
Analysis LC: introduce Symbol LC tests
2021-12-27 16:23:18 +03:00
Ilya Kirillov
aa87524513
Migrate stub and psi builders by classfiles form IJ repository
2021-12-27 16:23:16 +03:00
Ilya Kirillov
1e9764c639
Move stub building from psi module to analysis module
2021-12-27 16:23:14 +03:00
Ilya Kirillov
cd3905e400
Fix dependencies to intellij modules after gradle dependency DSL update
2021-12-27 16:23:13 +03:00
Ilya Kirillov
3779acbc3d
Add testdata from intellij for cls stub building tests and generate tests
2021-12-27 16:23:11 +03:00
Ilya Kirillov
02d68d7b12
Introduce cls stub building tests (mostly migrated from intellij)
2021-12-27 16:23:10 +03:00
Ilya Kirillov
127dc7670e
Move IDEKotlinBinaryClassCache from intellij
2021-12-27 16:23:10 +03:00
Ilya Kirillov
b222bf88a0
Move DirectoryBasedClassFinder and DirectoryBasedDataFinder from intellij
2021-12-27 16:23:10 +03:00
Ilya Kirillov
dbb3ebb8df
Implement AnnotationLoaderForClassFileStubBuilder
2021-12-27 16:23:09 +03:00
Ilya Kirillov
b9b0bb309d
Move KotlinClsStubBuilder from intellij repository
...
This commit is just move, without any modifications
2021-12-27 16:23:09 +03:00
Ilya Kirillov
52baf7338e
Move KotlinBinaryClassCache to separate module, so it can be used outside FE1.0
2021-12-27 16:23:08 +03:00
Ilya Kirillov
25fe14b514
Move PerformanceCounter to runtime utils, so it can be used outside FE1.0
2021-12-27 16:23:07 +03:00
Ilya Kirillov
3686fc109d
Extract AnnotationLoader from AnnotationAndConstantLoader, so it can be used without FE1.0
2021-12-27 16:23:07 +03:00
Ilya Kirillov
49e9c47071
Move DynamicTypeDeserializer.id from IR module to common module
...
So, it can be used from cls-psi-stub-builder module
2021-12-27 16:23:06 +03:00
Ilya Kirillov
53346e0aa6
Merge KotlinFileStubImpl and KotlinFileStubForIde into KotlinFileStubImpl
...
as the only difference is additional fields in KotlinFileStubForIde
2021-12-27 16:23:05 +03:00
Ilya Kirillov
a9d7e5db72
Move stub builder stuff from intellij
...
This is mechanical moving without fixing compilation errors,
just packages are changes
2021-12-27 16:21:51 +03:00
Hung Nguyen
78f10d9142
KT-45777: Keep only package facades whose members are looked up
...
to reduce the size of the shrunk classpath snapshot further.
2021-12-25 00:20:31 +03:00