Ivan Kochurkin
4e67d82cd3
[K2, MPP] Make MPP tests from k2/basic target-wide
...
^KT-57349
2023-03-24 14:48:27 +00:00
Ivan Kochurkin
ee73e4774b
[K2, MPP] Remove redundant expect declarations from klib metadata
...
^KT-57250 Fixed
Introduce flat Fir2IrActualizedResult
It contains output from Fir2Ir and IrActualizer
2023-03-24 14:48:26 +00:00
Vladimir Sukharev
9407ec35e3
KT-57487: Add codegen test
...
Merge-request: KT-MR-9300
Merged-by: Vladimir Sukharev <Vladimir.Sukharev@jetbrains.com >
2023-03-23 10:03:00 +00:00
Kirill Rakhman
45d2424ad8
[FIR] Let prefix inc/dec call getter twice for compatibility with K1
...
#KT-57179 Fixed
2023-03-21 08:48:38 +00:00
Svyatoslav Kuzmich
1b7c63bd49
[Wasm] Fix js interop closure signature
...
Before we used IrType.render() which is not unique.
This changes adds a proper serialization of adapter signature to string.
2023-03-20 15:16:00 +00:00
Artem Kobzar
7a79de6d16
[K/JS] Move JS IR box tests setup into separated function
2023-03-19 22:53:05 +00:00
Dmitriy Novozhilov
ca2492e1f8
[FIR2IR] Unwrap substitution overrides during generation of delegated members
...
^KT-55828 Fixed
2023-03-17 12:37:33 +00:00
Ilya Chernikov
be2a85be71
K2: support implicit integer to unsigned conversions...
...
with dedicated opt-in language feature and special
annotation or module capability.
Not intended for a general use, solves specific K/N
scenario with interop libs.
#KT-55902 fixed
2023-03-17 08:57:51 +00:00
Pavel Kunyavskiy
e655e0a809
[K/N] Fix default argument lambda in suspend function code generation
2023-03-16 21:14:41 +00:00
Svyatoslav Kuzmich
1208a26fc4
[Wasm] Use JsAny, JsHandle and other Js* types in stdlib and kotlin-test
2023-03-16 09:12:07 +00:00
Svyatoslav Kuzmich
1e91fe155b
[Wasm] Restrict types allowed in JS interop
...
- Prohibit Any, Array and other unsupported non-external types in JS
interop context
- Add K1 diagnostic
- Update BE testdata
^KT-57136 Fixed
2023-03-16 09:12:07 +00:00
Svyatoslav Kuzmich
bb05c8528f
[Wasm] Fix KtDeclarationWithBody.hasValidJsCodeBody
...
Empty bodies are not valid jsCode bodies.
2023-03-16 09:12:06 +00:00
Pavel Kunyavskiy
62fb3df7f0
[K/N] Disable scope initialization on constant access
...
^KT-57098
2023-03-15 09:03:19 +00:00
Ivan Kylchik
0af4ef8ee9
Fix typo in test name: inlinInDefault -> inlineInDefault
2023-03-14 20:47:43 +00:00
Ivan Kylchik
bb401c39d9
Add several new SMAP tests
...
Some of them are still failing and suppose to be
fixed later
2023-03-14 20:47:39 +00:00
Pavel Kunyavskiy
dc2e072af2
[K/N] Make exception handling in initializers more consistent with jvm
...
^KT-57091
2023-03-14 12:59:14 +00:00
Svyatoslav Kuzmich
1603cd11ea
[Wasm] Use jsshell version in zip and directory names
...
Otherwise, it wouldn't rerun the task when downloading new version
2023-03-10 14:03:26 +00:00
Vladimir Sukharev
65276e5960
[Testsystem] Insert missing opt-in
...
Merge-request: KT-MR-9158
Merged-by: Vladimir Sukharev <Vladimir.Sukharev@jetbrains.com >
2023-03-10 13:17:37 +00:00
Kirill Rakhman
0e721c8fc2
[FIR2IR] Fix generation of val initialization after smart-cast
...
If neither setter nor backing field were found for an assignment call,
search overridden properties for backing fields.
^KT-57105 Fixed
2023-03-10 09:30:51 +00:00
Kirill Rakhman
c4255cdb0f
[FIR2IR] Fix adapted callable reference to nested class constructor
...
^KT-56829 Fixed
2023-03-08 08:36:52 +00:00
Igor Chevdar
315d9089b0
[box-tests] Another version of reproducer for KT-56965
2023-03-08 06:48:52 +00:00
Igor Chevdar
99ec3215d9
[box-tests] Added a reproducer for KT-57053
2023-03-08 06:48:51 +00:00
Evgeniy.Zhelenskiy
88f293d4a9
[IR] Support reflection for MFVC
...
Signed-off-by: Evgeniy.Zhelenskiy <Evgeniy.Zhelenskiy@jetbrains.com >
#KT-1179
2023-03-07 21:44:43 +00:00
Zalim Bashorov
4d7cf81ed0
[Wasm] Stop supporting "_export.js" in test infra, use import/export capability in relevant tests
...
* It works slightly differently in SpiderMonkey.
* It was a hack.
2023-03-06 23:19:02 +01:00
Zalim Bashorov
bec827b654
[Wasm] Update SpiderMonkey to 112.0a1 (2023-03-04-09-52-24)
2023-03-06 23:19:02 +01:00
vladislav.grechko
7033d78641
Fix SAM conversion generation condition
...
Remove check if array is passed to vararg parameter as it's not
relevant anymore and leads to ^KT-51821.
^KT-51821: Fixed
2023-03-04 12:53:48 +00:00
Svyatoslav Kuzmich
7a04999e4a
[Wasm] Add K1 compiler diagnostics for js(code) calls (KT-56955)
...
This function is handled as intrinsics and supported in limited context
2023-03-03 19:39:10 +00:00
Svyatoslav Kuzmich
60ef7fcb49
[Wasm] Suppress unused parameters warning for functions with JS body
...
These parameters can be used in js(code)
2023-03-03 19:39:09 +00:00
Svyatoslav Kuzmich
71e6b19760
[Wasm] Support restricted version of js("code") (KT-56955)
2023-03-03 19:39:09 +00:00
Kirill Rakhman
1f0e6321b0
[FIR2IR] Use companion as bound receiver if expected type requires it
...
A::foo is preferably resolved as an unbound reference to A.foo, however
if A.Companion is a subtype of A and the expected type has one fewer
parameter than the type of the unbound reference, generate a bound
reference with the companion as receiver.
^KT-56519 Fixed
2023-03-02 10:55:46 +00:00
Kirill Rakhman
3b9724d20e
[FIR] Desugar increment/decrement in body resolve phase
...
The expression needs to be resolved first to determine if there is a
receiver that needs to be extracted to a temporary variable. Also, the
special case for prefix increment/decrement on local variable without
delegates requires resolution to check if the variable is local.
^KT-56771 Fixed
^KT-56659 Fixed
2023-03-02 10:19:57 +00:00
Kirill Rakhman
d00513599b
[FIR2IR] Expand typealias in callable reference receiver generation
...
^KT-56750 Fixed
2023-03-02 08:20:04 +00:00
Ivan Kochurkin
ee53c5780f
[FIR] Extract K2 MPP test data to the separated directory
2023-03-01 22:10:11 +00:00
Igor Chevdar
c038bbde08
[box-tests] Added a reproducer for KT-56965
2023-03-01 08:09:51 +00:00
Nikolay Lunyak
be5850112a
[FIR] KT-56723: Ensure safe access over non-expressions is always Unit
...
^KT-56723 Fixed
2023-02-27 15:00:30 +00:00
Svyatoslav Kuzmich
4be2f53b47
[Wasm] Add @JsFun diagnostics (KT-56944)
...
JsFun target should be top-level external function
2023-02-24 11:35:16 +00:00
Svyatoslav Kuzmich
1da96213ca
[Wasm] Add @WasmImport diagnostics (KT-56943)
...
WasmImport annotated functions:
* Restricted to top-level external functions
* Only supports primitive numbers, booleans and Unit
(as return type only) in its signature
* Can't have default parameter values
* Can't have vararg parameters
2023-02-24 11:35:16 +00:00
Svyatoslav Kuzmich
f79607d32d
[Wasm] Add @JsExport diagnostics test
...
@JsExport is only allowed on top-level functions in K/Wasm
Restrictions for nested function are handled by reusing K/JS diagnostics
Restrictions for classes and properties are handled by specifying
annotation target in stdlib
2023-02-24 11:35:16 +00:00
Svyatoslav Kuzmich
b4fcfd6719
[Wasm] Add external declaration diagnostics (KT-56940)
...
Prohibit:
- external enum class
- external tailrec fun
- external suspend fun
- external lateinit var
Add tests for other external diagnostics inherited from K/JS
2023-02-24 11:35:15 +00:00
Svyatoslav Kuzmich
83ba1ac0f7
[Wasm] Diagnostic test: dynamic type is unsupported
...
Validates the fix for KT-56711
2023-02-24 11:35:15 +00:00
Svyatoslav Kuzmich
c9e71985da
[Wasm] Stop dumping declarations in diagnostic tests
...
These tests are meant to check diagnostics, but
having to update .txt dumps adds some friction to development process.
2023-02-24 11:35:14 +00:00
Svyatoslav Kuzmich
321a476898
[Wasm] Add external inheritance checker.
...
Prohibit non-external types to extend external types.
This type of inheritance is not supported in Wasm backend.
2023-02-24 01:05:23 +01:00
Svyatoslav Kuzmich
54a45c49f8
[Wasm] Add Wasm platform and K1 FE infrastructure
2023-02-24 01:05:23 +01:00
Ilmir Usmanov
b3890885c4
JVM: Break infinite loop in finding meaningful instruction
...
during tail-call optimization.
There can be code, where all next instructions are non-meaningful and
there is a back-edge, for example, while(true){}. Previously, analyzer
incorrectly assumed, that this cannot happen. Now, it keeps track of
visited instructions and says, that there is no meaningful instruction
in such case.
#KT-56815 Fixed
2023-02-23 17:54:46 +00:00
Igor Chevdar
5d3b61364a
Added a test for KT-56500
2023-02-23 15:32:25 +00:00
Alexander Udalov
4ad594a3cd
Minor, move tests about Java field and Kotlin property
...
Because the `fieldRename` directory was originally about cases when
private fields are renamed because of clashes.
2023-02-23 12:54:00 +01:00
Denis.Zharkov
0c9fad87c3
K2: Fix deserialization of upper bound of type parameter in nested class
...
Previously, containingDeclarationSymbol for V was set to the outer class
BaseRoot, so its upper bounds was computed to the ones from TNested
at org.jetbrains.kotlin.fir.resolve.calls.CreateFreshTypeVariableSubstitutorStageKt.getTypeParameterFromExpandedClass
^KT-56706 Fixed
2023-02-21 12:35:34 +00:00
Ivan Kylchik
477d092bb8
Avoid object's interpretation with nullable type
...
#KT-56215 Fixed
2023-02-20 15:52:52 +00:00
Ilmir Usmanov
e42efe1ee6
JVM IR: Ignore class type parameters if function is static
...
Otherwise, it leads to type parameters duplication in case of
suspendImpls, since they inherit type parameters from containing class.
#KT-56407: Fixed
2023-02-07 13:39:25 +00:00
Vladimir Sukharev
e75d739c7a
Add tests for property const initializers
...
Merge-request: KT-MR-8661
Merged-by: Vladimir Sukharev <Vladimir.Sukharev@jetbrains.com >
2023-02-06 15:43:41 +00:00