Commit Graph

39 Commits

Author SHA1 Message Date
Michael Bogdanov
5bd045c79c Fix for KT-14243: Wrong invocation descriptor on calling implicitly generated implementation in class
#KT-14243 Fixed
2016-10-10 14:17:50 +03:00
Michael Bogdanov
95a1c254e1 Added error diagnostic on inheriting target 6 interface 2016-10-03 14:13:17 +03:00
Michael Bogdanov
d9bb519b76 Don't generate delegation to jvm8 default methods 2016-10-03 14:06:01 +03:00
Michael Bogdanov
c19e035f91 Properly map super calls in typeMapper 2016-10-03 14:06:00 +03:00
Michael Bogdanov
5f1f4a067d Map proper owner for method with default args 2016-10-03 14:06:00 +03:00
Michael Bogdanov
dd4d5e3aa1 Generate 'DefaultImpls' for jvm 8 target only within compiler option 2016-10-03 14:05:59 +03:00
Michael Bogdanov
ca41f01468 Generate interface property annotations in interface class (not in DefaultImpls) 2016-10-03 13:50:12 +03:00
Michael Bogdanov
dfd5be1a33 Generate all bodies in interfaces as default methods 2016-10-03 13:50:11 +03:00
Michael Bogdanov
69dc18b8b4 Proper concrete implementation filtering in java 8 interface case 2016-09-12 12:59:31 +03:00
Denis Zharkov
915e36cb02 Add Map.getOrDefault method as PlatformDependent declaration with refined signature
- First parameter should have type of K instead of Any
- Special bridge should return second parameter if a key has wrong type
- Special bridge may throw an exception if defaultValue has wrong type

 #KT-13209 Fixed
2016-07-27 18:46:13 +03:00
Denis Zharkov
f2cb86c3f6 Minor. Fix testData 2016-07-27 18:46:13 +03:00
Denis Zharkov
3845ea863c Do not generate DefaultImpl method for MutableMap.remove(K;V)Z
#KT-13069 Fixed
2016-07-12 16:27:48 +03:00
Denis Zharkov
7723a3a105 Refine definition of whether single parameter the method should be boxed
Only 'Collection<Int>.remove(E): Boolean' should match
2016-07-04 15:44:00 +03:00
Denis Zharkov
96eb3f411d Minor. Simplify 'async' tests 2016-06-19 12:50:54 +03:00
Denis Zharkov
07dcc6c616 Support 'handleException' operator in JVM backend 2016-06-19 12:50:53 +03:00
Alexander Udalov
b4f81d4bb5 Use 'JVM_TARGET: 1.8' directive in codegen tests on 1.8 target 2016-06-16 16:51:18 +03:00
Mikhael Bogdanov
1c3ce93275 Generate same delagation structure as in jvm 6 target until new binary compatibility design
We need to make some decision about binary compatibility beetwen targets and semantics, so now old logic is used
2016-06-15 13:43:29 +03:00
Mikhael Bogdanov
bb59638039 Support bridges in interfaces. Fix for KT-12416: Missed bridges in js backend
#KT-12416 Fixed
2016-06-15 13:43:28 +03:00
Mikhael Bogdanov
16159c483d Generate defaults methods on extending jvm6 interfaces 2016-06-15 13:43:27 +03:00
Mikhael Bogdanov
331341bd4d Don't generate delegates on overriding jvm8 interfaces 2016-06-15 13:43:27 +03:00
Michael Bogdanov
01aa89b1ea Generate delegation body for default interface methods, calculate proper abstractness for them 2016-06-15 13:43:26 +03:00
Mikhael Bogdanov
77a386a266 Move java8 'compileKotlinAgainstKotlin' test under 'codegen/java8/compileKotlinAgainstKotlin/jvm6' folder 2016-06-15 13:43:24 +03:00
Denis Zharkov
e802049fd0 Ignore handleReturn calls if functions is not operator 2016-06-08 18:53:16 +03:00
Denis Zharkov
75e112e752 Implement basic support for coroutines in JVM backend 2016-06-08 18:53:16 +03:00
Denis Zharkov
d259b91143 Add MutableMap.remove(K, V) as built-in declaration
Use PlatformDependent annotation to guarantee it's only be available for JDK8
Also adjust type-safe bridges and mutable collection stubs generation
2016-04-29 15:08:54 +03:00
Denis Zharkov
5bc5722051 Load additional JDK functions into built-ins member scope
#KT-5990 Fixed
 #KT-7127 Fixed
 #KT-10370 Fixed
2016-04-25 17:41:08 +03:00
Alexander Udalov
04eea69a82 Fix Java 8 codegen box tests 2016-03-03 17:08:47 +03:00
Alexander Udalov
933be1e035 Drop single-file mode of black box codegen tests
Add regression test for #KT-5190
2016-03-02 15:47:39 +03:00
Alexander Udalov
2de7f38427 Migrate boxWithJava tests to multi-file framework 2016-03-02 15:47:38 +03:00
Mikhail Glukhikh
4e44466cf9 Exposed visibility deprecation warnings made errors + relevant test fixes 2015-11-20 15:21:01 +03:00
Dmitry Jemerov
4ca434da54 remove support for 'trait' keyword 2015-09-22 15:00:24 +02:00
Alexander Udalov
89f3cfc704 Support parameter names for Java 8 classes in reflection
Also support specifying additional options to javac in codegen tests, which was
needed to compile Java sources with the "-parameters" option
2015-08-28 21:11:01 +03:00
Alexander Udalov
4dcc373a5a Fix concrete method inheritance in interfaces
For each non-abstract non-declared (i.e. inherited from supertypes) method in
an interface we generate its static form to the TImpl, which calls the TImpl
method from the corresponding supertype.

The accidental override tests changed because we're now trying to generate the
delegate for the super method, not knowing that it will clash with the declared
method

 #KT-2888 Fixed
 #KT-5393 Fixed
2015-06-17 16:23:56 +03:00
Michael Bogdanov
99cad4b43f Support default method invocation via super
#KT-5970 Fixed
2015-05-13 14:52:18 +03:00
Michael Bogdanov
3fbdf05921 Added some new test for java8 2015-05-13 14:52:18 +03:00
Dmitry Jemerov
4bdf598bfe compiler testdata: s/trait/interface 2015-05-12 19:43:17 +02:00
Michael Bogdanov
2f88f830b8 Test for KT-5969: Codegen overrides all java 8 default methods with delegation to unexisting Timpl
#KT-5969 Fixed
2015-04-18 14:45:16 +03:00
Michael Bogdanov
115c4b78c0 Added sam test on java8 interface with default method 2015-04-18 14:45:16 +03:00
Michael Bogdanov
7e3403f602 Add java8 test module and run configuration with initial test 2015-04-18 14:45:15 +03:00