Alexander Udalov
ddfa94e7e9
Support Nothing type in typeOf
...
The proper support will come in KT-15518, but that would be a breaking
change even for stable Kotlin without kotlin-reflect. Before that issue
is fixed, represent Nothing in types with the Void class, and use a flag
in the no-reflect implementation to remember that it's not actually the
Void class itself.
#KT-39166 Fixed
2021-07-09 14:40:05 +02:00
Victor Petukhov
c3a5a7754d
Use proper applicability for constraint warnings
...
^KT-47316 Fixed
2021-07-09 14:07:01 +03:00
Ilya Muradyan
787ce6335c
Change nestedClasses logic to accept classes with nested type aliases
...
#KT-47650 fixed
2021-07-08 21:04:53 +03:00
Dmitriy Novozhilov
11dfbd41ac
[Test] Delete obsolete descriptor renderer tests
2021-07-08 13:29:19 +03:00
Andrey Zinovyev
9fad55d551
[FIR] Use @DeprecatedSinceKotlin in the resolution
2021-07-07 16:19:27 +03:00
Victor Petukhov
50ad5116b5
Add CLI test for -Xnullability-annotations
2021-07-06 09:54:30 +03:00
Victor Petukhov
a82772f31a
Depend on passed language version explicitly to compute nullability annotation settings
2021-07-06 09:54:29 +03:00
Alexander Udalov
113632c49c
Psi2ir: load single-value Java array annotation arguments correctly
...
#KT-47467 Fixed
2021-07-05 21:49:10 +02:00
pyos
c3a91efea3
JVM_IR: fix primitive comparison optimizations
...
1. the `primitive == object?.something` fusion should not apply to
`primitive.equals(object?.something)` because it can't;
2. coercions to Int are there for a reason - don't remove them;
3. better optimize `primitive == object?.something` -- the result
should be subject to if-null fusion, so it needs to have a specific
pattern that resembles safe calls.
#KT-47597 Fixed
2021-07-05 18:13:09 +03:00
Dmitriy Novozhilov
ae608ea67f
[FE 1.0] Always create return value for CallInstruction
...
This fixes missing `USED_AS_EXPRESSION` recordings
^KT-47527 Fixed
2021-07-02 17:55:20 +03:00
Dmitry Petrov
584310615c
JVM_IR KT-47499 use proper signature for 'clone' intrinsic
2021-07-01 22:10:47 +03:00
Alexander Udalov
ae07127f08
JVM IR: support raw types in typeOf
2021-07-01 19:33:56 +02:00
Alexander Udalov
0cb905a4b1
Support mutable collection types in typeOf
...
flexibleTypes_1_6.kt is fixed for JVM IR in a subsequent commit.
#KT-35877 Fixed
2021-07-01 19:33:55 +02:00
Alexander Udalov
6e975b3498
Support flexible types internally in typeOf
...
#KT-45066 Fixed
2021-07-01 19:33:55 +02:00
Roman Artemev
5a284de2d4
add tests for private signatures
...
regenerate tests
add test for EnumEntry's argument declarations
add another test
regenerate test
fix test a bit
2021-07-01 17:40:27 +03:00
Dmitry Petrov
37b05cd9c2
JVM_IR KT-47120 treat outer name as case-insensitive for local classes
2021-06-30 14:04:22 +03:00
Dmitry Petrov
68c3f30aa7
JVM_IR KT-47510 indy callee parent is a package fragment, not a class
2021-06-29 17:00:31 +03:00
Alexander Udalov
4b7fa44e80
CLI: fix resolution of Java records as single file roots
...
#KT-46764 Fixed
2021-06-29 01:22:08 +02:00
Dmitry Petrov
768afc5ba4
JVM_IR KT-47492 fix 'for' loop generation
2021-06-28 21:07:54 +03:00
Roman Artemev
6993b86d3b
[IR] Fix IrCapturedType equals/hashCode
...
It could lead to SOE if CT has itself as superType
- fix KT-47424
2021-06-28 20:43:14 +03:00
Dmitry Petrov
560c269e05
PSI2IR KT-47450 prevent SOE when generating IR for deep expressions
2021-06-28 15:41:41 +03:00
Mikhael Bogdanov
5f62b72c82
Properly process big types
2021-06-26 06:10:16 +02:00
Mikhael Bogdanov
0fd1f549a9
Properly process special symbols during indy-with-constants concatenation
...
#KT-47320 Fixed
2021-06-26 06:10:16 +02:00
Dmitry Petrov
1298ba431b
JVM_IR KT-47449 handle star projection arguments in default lambda types
2021-06-25 20:42:22 +03:00
pyos
26e3237b8c
JVM_IR: never rename public/protected fields
...
And if that causes a platform declaration clash, that's not a problem
that can be solved without breaking the ABI anyway.
#KT-47412 Fixed
2021-06-24 17:41:06 +03:00
Denis.Zharkov
4892ad42b9
FIR: Do not mark not found classes' based types from Java as error
...
The same happens in FE1.0
2021-06-24 12:17:45 +03:00
Denis.Zharkov
201dded237
FIR: Fix serialization of delegated members
...
^KT-47413 Relates
2021-06-24 12:17:43 +03:00
Dmitry Petrov
0104b1275f
JVM_IR KT-47398 handle @EnhancedNullability String subject as in 1.0
2021-06-23 20:11:24 +03:00
Dmitry Petrov
c26d71c4ef
JVM KT-47365 add box test
2021-06-23 20:11:23 +03:00
Dmitry Petrov
f30fc4863c
JVM add ABI tests for non-approximated SAM types
...
Note that resulting SAM method
public final method accept(p0: java.lang.Object): void
has a signature less specific than the resulting bridge method
public synthetic bridge method accept(p0: X): void
2021-06-22 21:13:57 +03:00
Dmitry Petrov
c77884f067
Refactor SAM type handling, replace non-approximated arguments with *
2021-06-22 21:13:56 +03:00
Victor Petukhov
4aeabb6b0f
Use upper bound aware type approximator for intersection types inside sam types in contravariant positions to build proper types in terms of subtyping
2021-06-22 21:13:55 +03:00
Dmitry Petrov
c19792e7c5
JVM_IR KT-47326 downcast field receiver on JvmField lowering
2021-06-21 19:17:54 +03:00
pyos
cf660cf24a
JVM_IR: expect unboxed return value from suspend default stubs
...
#KT-47206 Fixed
2021-06-21 18:53:31 +03:00
Dmitry Petrov
ce107d06d4
JVM_IR add test for KT-47300
2021-06-17 21:40:30 +03:00
Roman Artemev
e82552975d
[TEST] support test muting in klib text tests runner
2021-06-16 21:16:54 +03:00
Roman Artemev
16ea3d9ae9
[TEST] Add IrText klib tests
2021-06-16 21:16:44 +03:00
pyos
6c1a5e1211
JVM: make inline function argument processing a bit shorter
2021-06-16 12:13:32 +02:00
Mads Ager
6b6ba77869
[JVM_IR] Trim the expression test string for null assertions.
...
^KT-47166 Fixed.
2021-06-11 21:54:04 +03:00
Dmitry Petrov
bf077b893c
PSI2IR KT-47245 handle declaration statements in control structures
2021-06-11 16:42:31 +03:00
pyos
1f9db7cf25
FE: properly clear the deferred generator stack
...
Before this commit the stack wasn't cleared for read variable case.
#KT-47168 Fixed
2021-06-11 15:56:20 +03:00
Andrey Zinovyev
ddc9c1bd1b
[FIR] Fix extension property reference resolution
...
On type with star projection
#KT-44372 Fixed
2021-06-09 15:15:28 +03:00
Dmitry Petrov
81b09ca09f
KT-46267 JVM_IR don't generate unnecessary ATHROW in lateinit var read
2021-06-07 20:02:24 +03:00
pyos
0bd8d16fe2
JVM_IR: fix Result types in continuations & remove more codegen hacks
...
#KT-47129 Fixed
2021-06-07 09:57:42 +02:00
Dmitry Petrov
7fd033adae
JVM_IR KT-47073 use type parameter upper bound for default value
2021-06-04 20:54:01 +03:00
Victor Petukhov
1e5998e0ba
Add constraints between two different stub variables instead of creating constraint error due to T1 isn't subtype of T2
...
^KT-44241 Fixed
2021-06-03 19:18:09 +03:00
Victor Petukhov
19c07e048a
Don't check suitability of a builder inference call if unrestricted builder inference is enabled
...
^KT-42139 Fixed
2021-06-03 17:28:40 +03:00
Victor Petukhov
124a14c8df
Use separate constraint position during call substitution as part of inferring postponed type variables
...
^KT-47052 Fixed
^KT-47082 Fixed
2021-06-03 12:37:17 +03:00
Ilmir Usmanov
7a2ecc58d4
Minor. Regenerate tests
2021-06-03 12:35:26 +03:00
pyos
d5d3d9f112
Add regression tests for KT-46890 and other stuff
2021-06-03 12:35:25 +03:00