Commit Graph

3163 Commits

Author SHA1 Message Date
Dmitry Savvinov ee8702d21e Load of testdata change due to contracts publishing
See changes in e2606b72bdbec2fea567d4127197707869eb801e
2018-08-30 16:19:55 +03:00
Ilmir Usmanov 208c3a51ab Use short jvm names for the annotation parameters 2018-08-30 16:19:44 +03:00
Ilmir Usmanov 22f9a6ce08 Add coroutines debug metadata: compiler
#KT-25557 Fixed
 #KT-25559 Fixed
2018-08-30 16:19:41 +03:00
Ilmir Usmanov fe451dce31 Implement correct is check for SuspendFunction
Add test for suspend functions with language version 1.2.
Minor edit in SuspendFunction docs.
2018-08-30 16:17:46 +03:00
Dmitry Petrov a205019156 Additional tests and fixes for function name mangling 2018-08-30 14:58:54 +03:00
Dmitry Petrov 99498eb7b8 Use 'name-hash' mangling scheme
'-' is allowed as a name character both in JVM and in Dalvik, but can't
be a part of a Java identifier.
2018-08-30 14:58:52 +03:00
Dmitry Petrov a56d1d3ce8 Mangle function names with inline class parameters
Avoid name clashes in cases such as

  inline class Login(val login: String)
  inline class Password(val password: String)

  fun validate(login: Login) { ... }
  fun validate(password: Password) { ... }
2018-08-30 14:58:50 +03:00
Denis Zharkov c6eaaac877 Adjust coroutines test data to changing the default LV to 1.3 2018-08-30 14:58:43 +03:00
Denis Zharkov f594cb22e8 Add "LANGUAGE_VERSION: 1.2" directive where it's necessary 2018-08-30 14:58:41 +03:00
Ilya Gorbunov 6d33313d2e Regenerate range iteration tests 2018-08-30 14:58:22 +03:00
Ilmir Usmanov b7b5fd75b8 Minor. Fix tests 2018-08-30 14:57:50 +03:00
Ilmir Usmanov e93683621a Implement callSuspend and callSuspendBy functions as KCallable's
extension methods.
Also make isSuspend a member of KCallable.
 #KT-21972: Fixed
2018-08-30 14:57:48 +03:00
Anton Bannykh a83baee67b review fixes + DCE data update + test (un)muting 2018-08-30 14:57:27 +03:00
Anton Bannykh 2663d9751a JS: support unsigned constants inside string templates 2018-08-30 14:57:24 +03:00
Anton Bannykh 6103df0b31 JS: support signed constant expressions as unsigned primitive arguments 2018-08-30 14:57:22 +03:00
Anton Bannykh 934e11aa60 JS: support unsigned primitive vararg's 2018-08-30 14:57:20 +03:00
Anton Bannykh 944c5b6044 JS: modify a test to work around Kotlin/JS Double.toString problems 2018-08-30 14:57:18 +03:00
Anton Bannykh a11c4871ea JS: equals, hashCode, toString support in inline classes 2018-08-30 14:57:16 +03:00
Ilya Gorbunov 2df78fc81a Introduce common ArithmeticException
Make divisionByZero test still fail in JS after introducing ArithmeticException
2018-08-30 14:56:59 +03:00
Alexander Udalov ceb909d261 Inherit KType from KAnnotatedElement, implement KType.annotations
#KT-16795 Fixed
2018-08-30 14:56:57 +03:00
Alexander Udalov b55fc818d1 Support JvmName on annotation constructor parameters
#KT-25372 Fixed
2018-08-30 14:56:42 +03:00
Alexander Udalov dc1f4c7d5b Generate get-targeted annotations on annotation constructor parameters
This change would also make NotNull annotations to be generated on
non-primitive annotation methods, but we skip this deliberately because
annotation methods never return null on JVM anyway

 #KT-25287 Fixed
2018-08-30 14:56:40 +03:00
Alexander Udalov cbc92bc9a1 Add KClass.sealedSubclasses to get direct subclasses of sealed class
#KT-14657 Fixed
2018-08-30 14:56:21 +03:00
Ilya Gorbunov 1b1713a849 Simplify long constants in range iteration tests 2018-08-30 14:56:19 +03:00
Ilya Gorbunov bb1ce52267 Add support for generating unsigned progression iteration codegen tests 2018-08-30 14:56:17 +03:00
Ilya Gorbunov f010231ff7 Change range iteration tests so they are runnable on all platforms
Remove JS and Native backend exclusions
2018-08-30 14:56:13 +03:00
Alexander Udalov 877dfd8ff4 Fix generic signature of FunctionN type visible from Java 2018-08-30 14:55:56 +03:00
Ilya Gorbunov 5f3a7f0147 Use Char.MIN_VALUE and MAX_VALUE in tests 2018-08-30 14:55:45 +03:00
Ilya Gorbunov 26b258af6a Unignore passing tests with unsigned literals in JS 2018-08-30 14:55:37 +03:00
Mikhail Zarechenskiy d94b47bcd3 Support other kinds of translation for unsigned literals 2018-08-30 14:55:34 +03:00
Mikhail Zarechenskiy 61efbea9a8 Initial support of unsigned literals translation in JS 2018-08-30 14:54:27 +03:00
Alexander Udalov c369e67e9f Revert "Ignore tests on big function types until master is 1.3"
This reverts commit f03dc62173.
2018-08-30 14:52:38 +03:00
Alexander Udalov 51979b9ffa Convert FunctionBase to Kotlin, add type parameter to Lambda
This will make it possible to avoid raw types when inheriting from both
FunctionBase and Function<R>. This change adds a generic type parameter
to FunctionBase and Lambda which is not source-breaking under our policy
because both FunctionBase and Lambda are internal classes (located in
package kotlin.jvm.internal)
2018-08-30 14:52:33 +03:00
Kerooker af5f78076c KT-7922 Added Boolean Companion Object 2018-08-30 14:51:04 +03:00
Denis Vnukov ddf92ef187 Creating IrLineNumberTestGenerated, adding line numbers for few common expressions
This PR enables LineNumberTestGenerated test on IR backend. The testing of
hardcoded sequence of line numbers is replaced with mere checks for set-like
checks for expected line numbers.
2018-08-29 12:52:20 +02:00
Pavel Punegov 1ea9c2d4ba Replace min with coerceAtMost in test 2018-08-28 13:48:44 +03:00
Pavel Punegov 1c5ebacf0f Disable 1.3 version coroutines in Native and incorrect genericProperty test 2018-08-28 13:48:44 +03:00
Pavel Punegov 9eb78fc490 Disable tests that fail in NATIVE 2018-08-28 13:48:44 +03:00
Pavel Punegov 39a65a099a Disable IEEE754 tests with improper comparisons behaviour in Native 2018-08-28 13:48:44 +03:00
Pavel Punegov 1a7d366733 Disable JVM tests in native 2018-08-28 13:48:44 +03:00
Pavel Punegov 0c8f34a934 Disable JVM assertions in native 2018-08-28 13:48:44 +03:00
Pavel Punegov 2ff6047845 Update ignore tag for Native backend 2018-08-28 13:48:43 +03:00
Mikhael Bogdanov ca5b19d0c6 Merge Java 8 write signature tests in common ones 2018-08-27 15:55:03 +02:00
Roman Artemev 5dcb02466a Update test data 2018-08-24 15:49:13 +03:00
Roman Artemev cc14442be1 Add tests for primitive companion object
Update test data
2018-08-24 14:58:42 +03:00
Dmitry Petrov 2a524920a5 Don't remap inline function args requiring inline class boxing/unboxing
Same as for primitives: inline lambda expects to see a boxed value,
so, even if an argument is a local variable, it can't be remapped,
because it contains unboxed representation.
2018-08-24 14:52:29 +03:00
Dmitry Petrov 6e2d05cd94 Fix argument original type order in InlineCodegen
Arguments are put on stack in the direct order, and then stored into
local variables for inlining in the reversed order:

    <arg0>
    <arg1>
    <arg2>
    store <param2>
    store <param1>
    store <param0>

Original value parameter types were taken in direct order, though.
2018-08-24 14:52:29 +03:00
Roman Artemev 0895f72570 Fix testdata 2018-08-23 14:10:11 +03:00
Ilmir Usmanov 0559cfb724 Move SuspendFunction{N} interfaces to kotlin.coroutines package
#KT-25824: Fixed
2018-08-22 16:21:30 +03:00
Ilmir Usmanov 4a7703ed66 Implement correct is check for SuspendFunction
Let callable references implement SuspendFunction
Do not generate CHECKCAST SuspendFunction when LV is 1.2

 #KT-25825: Fixed
2018-08-22 16:21:27 +03:00