Dmitry Petrov
98b0c07b18
JVM_IR indy-SAM conversions: inline funs and lambdas
...
KT-44278 KT-26060 KT-42621
2021-01-29 12:59:47 +03:00
Dmitry Petrov
4da2f3d9d4
JVM_IR indy-SAM conversions: use old scheme for suspend funs
...
KT-44278 KT-26060 KT-42621
2021-01-29 12:59:46 +03:00
Dmitry Petrov
1f16b96796
JVM_IR indy-SAM conversions: inline classes
...
KT-44278 KT-26060 KT-42621
2021-01-29 12:59:46 +03:00
Dmitry Petrov
f30e25aa52
JVM_IR indy-SAM conversions: more cases
...
KT-44278 KT-26060 KT-42621
2021-01-29 12:59:45 +03:00
Dmitry Petrov
3140cca050
JVM_IR indy-SAM conversions, 1st passing tests
...
KT-44278 KT-26060 KT-42621
2021-01-29 12:59:45 +03:00
Denis.Zharkov
7e6abffb62
FIR: Fix incorrectly serialized type
...
See the test added: there's a non-denotable T!! type inside flexible type
that wasn't handled before.
ConeKotlinType::contains handles flexible types content and some other cases
Also, it has better asymptotics
2021-01-29 10:50:23 +03:00
Denis.Zharkov
5c62ee4ba8
FIR2IR: Fix complex cases of smart cast expressions used as dispatch receiver
...
It might be not only <ExpressionWithSmartCast>(a).foo(), but also
id(<ExpressionWithSmartCast>(a)).foo() and many other cases
2021-01-29 10:50:22 +03:00
Denis.Zharkov
b1b89e6f5f
FIR2IR: Fix smart-cast approximation implicit receiver
...
Previously, it was always cast to the first type of smart cast variants list
independently of callee symbol that might be present in the member scope
of a different type
2021-01-29 10:50:22 +03:00
Mikhael Bogdanov
b16b1b3b78
Test for obsolete KT-26360
...
#KT-26360
2021-01-28 18:01:21 +01:00
Mikhail Glukhikh
1c80c5610d
FIR: fix serialization of accessor with source-level annotations
2021-01-28 13:21:16 +03:00
Victor Petukhov
ba44ad1aa3
Approximate anonymous return types for private inline functions to explicit supertype or Any (KT-33917)
2021-01-28 13:19:32 +03:00
Victor Petukhov
670f029bdf
Allow passing non-spread arrays into a vararg parameter after sam properly, through propagating vararg element type to a sam adapter from the original parameter descriptor
2021-01-28 13:19:31 +03:00
Mikhail Glukhikh
ce1f9882df
FIR2IR: Fix mapping for intersection overrides of deserialized functions
2021-01-27 15:42:04 +03:00
Mikhail Glukhikh
76c2288e21
IrInterpreter: interpret IrGetField properly
2021-01-26 16:19:14 +03:00
Mikhail Glukhikh
b311e95487
FIR2IR: don't generate IR getter for const library properties
2021-01-26 16:10:09 +03:00
Dmitry Petrov
708e6914bd
JVM JVM_IR hide sealed class constructors
2021-01-25 17:29:38 +03:00
Mikhail Glukhikh
4cd6266bce
FIR: fix suspend type serialization
2021-01-23 10:56:40 +03:00
Mikhail Glukhikh
afe335e504
FIR: serialize ExtensionFunctionType attribute
2021-01-23 10:56:37 +03:00
Ilmir Usmanov
704366e531
JVM: Mark suspend lambda receiver as used if callable reference
...
accesses it.
#KT-44131 Fixed
2021-01-21 12:47:59 +01:00
Ilmir Usmanov
952576e98f
JVM_IR: Do not unbox Result parameter if it not only one inline class
...
parameter, since in this case, the compiler generates a bridge, where
the result is unboxed.
2021-01-20 18:30:00 +01:00
Ilmir Usmanov
d48f92775b
JVM_IR: Do not unbox Result parameter in invoke if there is a bridge
...
since the bridge unboxes it.
#KT-44141 Fixed
2021-01-20 18:29:58 +01:00
Ilya Goncharov
50ab9ed054
[JS IR] Add test on interface with default method calling extension method on super-interface
...
^KT-42176 fixed
2021-01-20 14:26:38 +03:00
Ilmir Usmanov
cce9469e6a
JVM_IR: Do not unbox Result parameter in Result methods
...
#KT-44140 Fixed
2021-01-20 06:27:15 +01:00
pyos
29f95c7df2
FIR: improve inference of implicit type arguments in casts
...
Type parameters do not necessarily match one-to-one, or preserve order.
2021-01-18 18:01:03 +03:00
Mads Ager
250cc1dc92
[JVM] Never treat arguments to methods as locals that can be removed.
...
Fixes KT-44347
2021-01-15 10:33:11 +03:00
Dmitriy Novozhilov
85c87f7df9
[Test] Migrate AbstractBlackBoxCodegenTest to new infrastructure
2021-01-12 18:35:30 +03:00
Dmitriy Novozhilov
285ccf7583
[Test] Don't generate JVM BB tests for expect-actual linker
...
This feature is supported only on JS backend so those tests on JVM
are meaningless. Also those tests had passed on jvm because of
old codegen tests didn't use `MODULE` directive and analyze all
files in tests in single module
2021-01-12 18:35:27 +03:00
Dmitriy Novozhilov
e0cd830a0e
[Test] Drop codegen tests for experimental coroutines
...
Experimental coroutines was deprecated in Kotlin 1.3,
so since Kotlin 1.5 we don't support (and don't test) them
2021-01-12 18:35:18 +03:00
Svyatoslav Kuzmich
ab753625fe
[JS Legacy] Fix returning Char from suspend functions (KT-44221)
...
Mark translated expression with a proper type, like we do with
non-suspending calls, to coerce it later.
2021-01-12 15:42:31 +03:00
Svyatoslav Kuzmich
2d88ff6fb2
[JS IR] Fix unsgined integer default arguemtns (KT-44180)
...
Const lowering didn't exprect null constants with unsigned number
types and crashed with NPE. This commit fixes that.
2021-01-12 15:42:31 +03:00
Dmitry Petrov
b02a9846d0
IR KT-44233 support flexible nullability in IrTypeSystemContext
...
^KT-44233 Fixed Target versions 1.5-M1
2021-01-11 17:33:50 +03:00
Mads Ager
dfc86feecd
[IR] Extend test coverage for smart cast handling.
2021-01-11 12:01:48 +03:00
Jinseong Jeon
f8f08e8134
IR: add a test about maximum number of constants in an enum class
2021-01-07 23:00:37 +01:00
Alexander Udalov
ed9a0e514d
Regenerate tests and fir-tree
2021-01-03 14:53:41 +01:00
Shagen Ogandzhanian
e7dc199ad7
Init enum entries whenever we access companion object or accessing valueOf
...
Fixes https://youtrack.jetbrains.com/issue/KT-43987
Fixes https://youtrack.jetbrains.com/issue/KT-43989
2020-12-30 14:54:34 +01:00
Dmitry Petrov
7fa04afda2
JVM_IR KT-32115 fix $$delegatedProperties initialization in enum
2020-12-30 15:56:18 +03:00
Dmitry Petrov
81e00ca371
JVM box tests for KT-30402
2020-12-30 10:57:46 +03:00
Ilmir Usmanov
80289e4a3f
IC Mangling: Generate inline class literal instead of underlying type
...
literal in annotations.
#KT-30280 Fixed
2020-12-30 03:31:08 +01:00
Victor Petukhov
30a5eee481
Don't approximate abbreviation during substitution it as it can't be projected at top-level
...
^KT-42036 Fixed
2020-12-29 16:08:38 +03:00
Dmitry Petrov
5d4b0b19d4
JVM_IR KT-13213 split string constants into parts of acceptable length
2020-12-28 16:50:29 +03:00
Denis.Zharkov
acbf382d04
FIR: Add test on ambiguous vararg
...
Fix is in the two previous commits
2020-12-28 13:19:23 +03:00
Victor Petukhov
37473ad640
Substitute lambda's receiver type during completion including the builder inference stub variables substitution
...
^KT-42175 Fixed
2020-12-25 21:33:37 +03:00
Mikhail Glukhikh
776c4ba6ca
Add test for KT-25489 (to reproduce, turn UL classes OFF)
2020-12-25 14:06:16 +03:00
Victor Petukhov
7ed6aae46e
Fix tests after rebasing
2020-12-25 11:53:21 +03:00
Victor Petukhov
1926434b18
Report error about uninferred type parameter for some special call' subcalls
2020-12-25 11:53:14 +03:00
Dmitry Petrov
9b148325fe
Minor: regenerate tests
2020-12-25 09:41:06 +03:00
Dmitry Petrov
a1574bf50a
JVM box tests for KT-30548
2020-12-24 19:35:36 +03:00
Ilmir Usmanov
9c67d8f89e
IC Mangling: Correctly mangle functions with generic return type
...
if the type's parent is inline class.
#KT-43050 Fixed
#KT-26130 Fixed
#KT-32384 Fixed
2020-12-24 14:29:48 +01:00
Dmitry Petrov
4e261cc358
JVM_IR KT-24258 fix NPE message for delegated properties
2020-12-23 21:50:10 +03:00
Dmitry Petrov
ad8bed078f
JVM box tests for KT-24193
2020-12-23 21:50:09 +03:00