Dmitriy Novozhilov
e94a64a4f2
[FE Test] Move FIR dumps for LoadCompiledKotlin tests close to original testdata
2023-04-19 14:33:24 +00:00
Dmitriy Novozhilov
de33a21fd1
[FE Test] Rename nested directory in testdata into nestedClasses
...
This is needed to avoid clash between generated test class `Nested` and
`@Nested` annotation from JUnit 5
2023-04-19 14:33:24 +00:00
Jinseong Jeon
0ca86c86be
SLC: add nullability annotation to value param of non-synthetic enum members
...
^KT-57567
2023-04-19 16:14:23 +02:00
Jinseong Jeon
9fe30bfc12
SLC: regression test for final modifier on enum members
...
^KT-57567
2023-04-19 16:14:23 +02:00
Ivan Kylchik
6b75b3bc4a
[IR] Drop duplicated meta info from interpreters tests
2023-04-19 13:52:48 +00:00
Ivan Kylchik
3f60c83921
[IR] Add id method in interpreter's tests to avoid optimizations
2023-04-19 13:52:48 +00:00
Ivan Kylchik
621f5a0fb7
[IR] Reorganize test files in involvesIrInterpreter dir
2023-04-19 13:52:48 +00:00
Ivan Kylchik
c00c7ffbe0
[K2] Use file name as one of parameters to extract evaluated const
...
It is not enough to store evaluated constants only by
<startOffset, endOffset> pair. We need to consider case there constant
can be located in different files with the same offset but with
different values.
#KT-57928 Fixed
#KT-57929 Fixed
2023-04-19 13:52:46 +00:00
Ivan Kylchik
8cc8e54a9f
[IR] Extract toString interpretation test of float value into new file
...
We need to distinguish `toString` results for JVM and JS
2023-04-19 13:52:46 +00:00
Ivan Kylchik
45aacae945
[K2] Rewrite the way of extraction const values from IR for FIR
...
Right now it is much easier to extract constant values from
`EvaluatedConstTracker`
#KT-57928
#KT-57929
2023-04-19 13:52:44 +00:00
Ivan Kylchik
1ddcdcfc39
[IR] Rewrite logic around object interpretation
...
Basically we want to allow object interpretation only when we try
to access some const val property.
#KT-57810 Fixed
2023-04-19 13:52:44 +00:00
Ivan Kylchik
5956e9b500
[IR] Print evaluated const directly into interpreter's tests
2023-04-19 13:52:44 +00:00
Ivan Kylchik
0b70b7904d
[K2] Create and add EvaluatedConstTracker in configuration
2023-04-19 13:52:43 +00:00
Ivan Kylchik
37c3dff0c5
[K2] Add new class to keep track of evaluated const by IrInterpreter
2023-04-19 13:52:42 +00:00
Ivan Kylchik
297b6ae64b
[K2] Move ConstantValue from fir-serialization to compiler.common
...
This is needed to be able to save `ConstantValue` in map of
evaluated constants.
2023-04-19 13:52:42 +00:00
Ivan Kylchik
fe989d0ba7
[K2] Add languageVersionSettings to Fir2IrConfiguration class
2023-04-19 13:52:42 +00:00
Ivan Kylchik
e16231104e
[K2] Add Fir2IrConfiguration class to store configuration parameters
...
One example of such parameter is `linkViaSignatures`. There is
`Psi2IrConfiguration` as an analog for K1.
2023-04-19 13:52:41 +00:00
Ivan Kylchik
525098dea6
[K2] Unbind fir:fir2ir:jvm-backend from other non jvm modules
2023-04-19 13:52:41 +00:00
Artem Kobzar
33c5068b79
[K/JS] Rework IR deserialization and lowering phases to consume less memory
2023-04-19 13:10:19 +00:00
Ilya Chernikov
8cc9f911d5
FIR: temp: make klib symbol provider know parent packages
...
Current qualified access resolving algo rely (likely incorrectly,
see #KT-58037) on a providers' "knowledge" about parent packages.
This commit adds this "knowledge" to k-lib based provider.
#KT-57353 fixed
2023-04-19 11:42:03 +00:00
Alexander.Likhachev
ec4fab57a7
[Build] Add the kotlin- prefix to the build tools API modules names
...
KT-57396
2023-04-19 09:09:26 +00:00
Mikhail Glukhikh
b6fdc2dbfc
DiagnosticReporterByTrackingStrategy: replace TODO() with assertions/errors
...
#KT-55079 Fixed
2023-04-19 07:24:05 +00:00
Mikhail Glukhikh
d4f81cf67f
K1: remove unused resolution diagnostic
...
Related to KT-55079
2023-04-19 07:24:05 +00:00
Pavel Mikhailovskii
3bb66e8432
KT-57714 Fix remapping of signatures with reified type parameters
2023-04-19 07:20:51 +00:00
Vladimir Dolzhenko
e10e821cd4
Fix onTheFlyDiagnosticsCallback
...
KtNamedFunction, KtClass etc are KtAnnotated.
Annotation recursion could happen within onTheFlyDiagnosticsCallback if
KtAnnotated has some annotations.
#KTIJ-25219
Merge-request: KT-MR-9652
Merged-by: Vladimir Dolzhenko <Vladimir.Dolzhenko@jetbrains.com >
2023-04-18 19:44:00 +00:00
Alexander.Likhachev
0727ee5a4f
[Gradle] Use custom classloader and ServiceLoader to load bt-api implementation
...
#KT-57397 Fixed
2023-04-18 18:19:25 +00:00
Alexander.Likhachev
9127919e01
[Build] Enable explicit API mode for build-tools-api
...
#KT-57396 Fixed
2023-04-18 18:19:23 +00:00
Alexander.Likhachev
7d29d34bf9
[Build] Configure binary-compatibility-validator for build-tools-api
...
#KT-57396 In Progress
2023-04-18 18:19:23 +00:00
Alexander.Likhachev
3a8d7c0839
[Build] Add build-tools-api and build-tools-impl modules
...
#KT-57396 In Progress
2023-04-18 18:19:23 +00:00
Mikhail Glukhikh
9374202ebc
FirCallResolve: disable property resolve optimization in builder inference
...
#KT-57889 Fixed
2023-04-18 17:05:01 +00:00
Mikhail Glukhikh
f9a7a7fda2
K2: reproduce KT-57889
2023-04-18 17:05:00 +00:00
Zalim Bashorov
34f8851ac1
[psi2ir] Ignore private members when creating fake overrides from descriptors
...
The behavior is unified with the IR deserializer.
See `isOverridableMemberOrAccessor` in IrOverridingUtil.kt
Without this change, if we add a private member to the Any in wasm stdlib,
the compiler starts crashing with a linker error.
It's hard to write a relevant, self-contained box test for that since it requires
adding a private member to Any and affects **only** "virtual" FunctionN interfaces.
2023-04-18 18:44:47 +02:00
Kirill Rakhman
ff7072830f
[FIR] Make lambda parameters of dynamic function calls dynamic
...
#KT-57961 Fixed
2023-04-18 13:43:45 +00:00
Kirill Rakhman
a3bf61c3f7
[FIR] Fix false positive error for trailing lambda on dynamic call
...
#KT-57961
2023-04-18 13:43:44 +00:00
Dmitriy Novozhilov
faf212ca04
[FIR] Don't extract contracts in DFA during non-body resolution stages
2023-04-18 13:31:29 +00:00
Dmitriy Novozhilov
bde4d003be
[FIR] Extract contracts from original functions of fake overrides
...
^KT-57911 Fixed
2023-04-18 13:31:29 +00:00
Dmitriy Novozhilov
f8dc8057f0
[FIR] Prohibit referencing type parameters in contracts ...
...
...if they are not reified or not belong to owner declaration of the contract
KT-57911
2023-04-18 13:31:28 +00:00
Dmitriy Novozhilov
5a92eb2c67
[FIR] Properly track problems in contract description during effect extraction
2023-04-18 13:31:28 +00:00
Alexander Korepanov
79d378f2bd
[JS IR] Perform optimizations on the generated JS code
...
The patch adopts and reuses the optimizations from the legacy backend.
The optimizations remove useless temporary variables,
statements and simplify generated JS code.
The optimizations can be disabled by `-Xoptimize-generated-js=false`.
Related to KT-51139
2023-04-18 12:49:33 +00:00
Alexander Korepanov
84b5af3c89
[JS IR] Style fixes
2023-04-18 12:49:32 +00:00
Svyatoslav Scherbina
54c07f5ebb
Ignore K2 expectPropertyAsDefaultArgument.kt test for K1/Native
...
It is not supposed to work with K1 on Native due to test infrastructure
limitations, and actually fails in one of the compilation modes in
nightly tests.
2023-04-18 10:43:51 +00:00
Mikhail Glukhikh
50f82c9094
FirBuilderInferenceSession: fix calculation of effectivelyEmptyCommonSystem
...
#KT-57873 Fixed
2023-04-18 09:23:20 +00:00
Mikhail Glukhikh
7bd5491498
K2: reproduce KT-57873
2023-04-18 09:23:20 +00:00
Dmitriy Dolovov
66797ff876
[PL] Temporarily disable PL for WASM
2023-04-18 09:22:54 +00:00
Dmitriy Dolovov
87125d0703
[PL] Fix: Don't run partial linkage on early stages when no external dependencies have been loaded yet
2023-04-18 09:22:54 +00:00
Dmitriy Dolovov
000cf47c21
[PL][JS] Fix: Pass PL CLI arguments properly
2023-04-18 09:22:53 +00:00
Dmitriy Dolovov
9d3deb7e0e
[PL] Fix: Don't count value arguments vs value parameters for external functions
2023-04-18 09:22:52 +00:00
Dmitriy Dolovov
b644fc009d
[PL] Fix: Constructor of external class may delegate to kotlin.Any regardless of the actual superclass
2023-04-18 09:22:52 +00:00
Dmitriy Dolovov
997b6e6722
[PL] Fix: Don't try to implement non-implemented fake overrides in stdlib & co
2023-04-18 09:22:51 +00:00
Dmitriy Dolovov
dd8eedb8da
[PL] Fix: Don't try to implement non-implemented overridden callables in case of inheritance delegation to Nothing
2023-04-18 09:22:51 +00:00