Alexander Udalov
463728a96a
Fix compiler test on Throws+delegation for 1.4
...
No exceptions are generated for delegation in 1.4 (see KT-35834).
2020-01-17 12:47:20 +01:00
Alexander Udalov
de683c0768
JVM IR: mute more tests after advancing language to 1.4
2020-01-17 12:47:20 +01:00
Dmitry Petrov
135cd6fd77
Enable ProperIeee754Comparisons in KOTLIN_1_4
2020-01-17 14:15:32 +03:00
Dmitry Petrov
933ac3a16b
Fix nullable number comparisons in JS
2020-01-17 14:14:59 +03:00
Dmitry Petrov
f8341ad7eb
JVM: Update tests for IEEE 754 comparisons
2020-01-17 14:14:59 +03:00
Dmitry Petrov
d5ff1047a5
JVM: Fix IEEE 754 comparison generation for boxed numbers
2020-01-17 14:14:58 +03:00
Alexander Udalov
26f435eb90
JVM IR: mute tests which fail after advancing language to 1.4
2020-01-17 12:07:30 +01:00
Alexander Udalov
e7864c7351
Fix inlineCallsStaticMethodFromOtherPackage.kt by disabling related language feature
...
This test is not possible for 1.4, where protected calls from public
inline functions are prohibited.
2020-01-17 12:07:30 +01:00
pyos
82ddd700ce
JVM_IR: patch parents of defaults in MemoizedInlineClassReplacements
...
A minor fix for #2909
2020-01-17 11:03:04 +03:00
Dmitriy Novozhilov
76b3964e96
Update testdata according to change compiler version to 1.4
2020-01-17 10:33:50 +03:00
Nikolay Krasko
ca49672a7a
Advance version to 1.4
2020-01-17 10:33:50 +03:00
Nikolay Krasko
fd8ff463bb
JUnit 4 runner for ignoring muted tests
2020-01-16 20:37:58 +03:00
Mikhail Zarechenskiy
4f74515508
[NI] Fix CST calculation for covariant type projections
2020-01-16 17:18:20 +03:00
pyos
6e6f4d0503
IR: close over the set of captured type parameters
2020-01-16 16:37:40 +03:00
Ilya Gorbunov
3d7c7c4656
Add problem zip file name when unable to open it
2020-01-16 16:01:55 +03:00
Ilya Gorbunov
9566f329f0
Mute FIR test failures and adjust failing test data due to KT-35948
2020-01-16 15:36:19 +03:00
Ilya Gorbunov
0f6df5971b
Mute tests failing in JS_IR backend due to KT-35944
2020-01-16 15:36:16 +03:00
Ilya Gorbunov
b3ecf84c43
Improve unexpected declaration exception message
2020-01-16 15:36:02 +03:00
Ilya Gorbunov
ac790bea71
Reorganize diagnostics tests with stdlib and reflect
...
DiagnosticsTestWithStdLib now require stdlib only.
Move test data accordingly.
The only test that required kotlin-reflect is transformed into
codegen box test.
2020-01-16 15:35:58 +03:00
Ilya Gorbunov
ec6fdc5d4d
Fix noStdlib cli test
...
Replace 'isExternal' with 'name', since 'name' is still available in builtins and 'isExternal' is only accessible with a proper stdlib dependency.
2020-01-16 15:33:16 +03:00
Ilya Gorbunov
8af43155c3
Remove reflect API not actually supported in K/JS
...
#KT-32186
2020-01-16 15:33:16 +03:00
Alexander Udalov
0815ed2cbd
JVM IR: do not load KDeclarationContainer from builtins
...
Like other classes declared in the standard library, construct a mock of
it in JvmSymbols. This is needed to move classes in kotlin.reflect out
from builtins and to the JVM part of the standard library.
2020-01-16 15:33:15 +03:00
Mikhail Glukhikh
f27611939e
Raw FIR builder: fix situation with explicit type of for parameter
...
Before this commit we omitted for parameter type,
even if it was stated explicitly. This also fixes PSI consistency test
2020-01-16 14:46:50 +03:00
Alexander Udalov
621936e951
Do not generate Throws attribute for delegated members from Kotlin interfaces
...
#KT-31763 Fixed
#KT-35834
2020-01-16 12:43:09 +01:00
Alexander Udalov
79d7335b8d
JVM IR: minor, add toString for FunctionHandleForIrFunction
...
Useful for debugging problems in BridgeLowering.
2020-01-16 12:38:16 +01:00
Alexander Udalov
86996bf546
IR: workaround exceptions in IrElement.dump
...
Fallback to IrElement.render if exception happens in DumpIrTreeVisitor
(due, for example, to invalid IR structure).
2020-01-16 12:38:03 +01:00
Alexander Udalov
c3d5a88e52
Add -Xno-use-ir to compiler modules where JVM IR currently fails
...
This option has no effect on the production code. But in a custom
scenario of a local bootstrap, where the compiler is replaced with the
one where JVM IR backend is enabled by default, this option allows to
switch back to the old backend.
All of these arguments (except the one for compiling experimental
coroutines) are supposed to go away as soon as we fix related problems
in the JVM IR backend.
2020-01-16 12:21:47 +01:00
Pavel Kirpichenkov
fd1305c369
[NI] Refactor OnlyInputType annotation check
...
Hold position consumed during incorporation in Constraint instead of ConstraintPosition.
2020-01-16 12:01:07 +03:00
Pavel Kirpichenkov
0d393e3fd7
[NI] Update filtering of constraints with equal types
...
Make check for synthetic nullability constraint status before skipping
new constraint with nonunique type.
2020-01-16 12:01:06 +03:00
Pavel Kirpichenkov
2896642f94
[NI] Consider synthetic lower nullability constraint non-proper
2020-01-16 12:01:06 +03:00
Denis Zharkov
676c99b933
NI: Fix exception during callable references overload resolution
...
^KT-35847 Fixed
2020-01-16 10:49:49 +03:00
Mikhail Zarechenskiy
588259a034
Add feature that allows references to synthetic properties with warning
...
See KT-35933 for details
2020-01-16 09:37:34 +03:00
Dmitriy Novozhilov
5111d1721a
[TEST] Add js runtime to failing box test
2020-01-15 22:12:29 +03:00
Dmitriy Novozhilov
a3037a081e
[NI] Fix resolve of lambdas with expected function type with receiver
...
#KT-30245
2020-01-15 22:12:29 +03:00
Dmitriy Novozhilov
7733611c47
[TEST] Replace Experimental with OptIn in testdata
2020-01-15 22:12:28 +03:00
Dmitriy Novozhilov
04ce10b6c1
[NI] Improve completing callable references with type variable as expected type
...
#KT-32462 Fixed
2020-01-15 22:12:28 +03:00
Alexander Udalov
6fe214d825
JVM IR: fix handling of suspend extension lambdas with captured receiver
...
The problem in the added test was that a suspend lambda was represented
by a function reference with a bound argument for the ObjectRef value,
and the corresponding parameter was not the first parameter of the
referenced local function. This happens because
LocalDeclarationsLowering lifts the local function up and adds a
new parameter for the captured ObjectRef (which is bound at the call
site), but the original receiver parameter remains the first unbound
parameter. So, it's no longer correct to rely on the fact that all bound
parameters of a function reference are located in the beginning of the
parameter list, which was kind of assumed in the `withIndex` call in
`AddContinuationLowering.addCreate`.
2020-01-15 19:42:13 +01:00
Alexander Udalov
f45ca7acd3
Add -Xno-use-ir to override useIR flag for custom-built compiler
2020-01-15 19:39:07 +01:00
Ilmir Usmanov
4fa8266606
Unconditionally remove $$forInline suffix from enclosing method
...
when transforming objects with suspend functions/lambdas, which
capture crossinline suspend lambdas. Since functions with the
suffix have a counterpart without the suffix, for java interop
and reflection call purposes, it is safe change.
#KT-31242 Fixed
2020-01-15 15:12:26 +01:00
Mikhail Glukhikh
7bcd3c4c13
[FIR] Introduce & use FirScopeProvider.getStaticMemberScopeForCallables
2020-01-15 16:52:13 +03:00
Mikhail Glukhikh
aaace40912
[FIR] Split Receiver/ReceiverValue, QualifierReceiver/ExpressionReceiver
2020-01-15 16:52:13 +03:00
Mikhail Glukhikh
42ba54fffd
[FIR] Add test for qualifier resolve priority
2020-01-15 16:52:12 +03:00
Mikhail Glukhikh
cef71b0349
[FIR] Add static / companion ambiguity to test data
...
This is temporary test data change until we prioritize this properly
2020-01-15 16:52:12 +03:00
Mikhail Glukhikh
f0ced642d9
[FIR] Use static & qualified scopes to access qualified callables
...
This commit provides more correct logic for creating scopes based
on FirResolvedQualifier & eliminates QualifiedReceiverTowerDataConsumer
2020-01-15 16:52:12 +03:00
Dmitry Petrov
6bbfb2ffe9
JVM: add tests for companion object accessor generation
2020-01-15 16:40:06 +03:00
Dmitry Petrov
3d85e5da5f
Enable ProperVisibilityForCompanionObjectInstanceField in 1.4
2020-01-15 16:40:06 +03:00
pyos
02722e0238
JVM_IR: mark the exception local as live only after the store
...
Otherwise, should the local coincide with another one, the incorrect
range causes D8 to generate invalid bytecode in debug mode.
2020-01-15 14:35:15 +01:00
Denis Zharkov
bcad6aeda6
Fix project compilation after fix for KT-35920
...
See KT-35931 for a feature request allowing to write IrConstImpl::int
2020-01-15 16:10:34 +03:00
Denis Zharkov
d4c34afb94
NI: Do not resolve static callable references on generic types
...
As they weren't resolved in old inference
^KT-35920 Fixed
2020-01-15 16:10:34 +03:00
Denis Zharkov
c48539feb3
NI: Fix callable references resolution when LHS is generic nested class
...
In case of null qualifier, we should not look into any static scope
NB: factory::createCallableProcessor returns NoExplicitReceiver processor
in case of null-receiver, that makes resolving the call in the test as
`property(::key)` that matches to the property itself, thus leading to
overload resolution ambiguity
^KT-35887 Fixed
2020-01-15 16:10:34 +03:00