Commit Graph

9 Commits

Author SHA1 Message Date
Alexander Udalov
35e956609a Rewrite mutable collection stub method generation
The main problem of the previous approach was that we were only generating
erased method signatures, which was incorrect in case a class also had a member
from another supertype with the same signature as the substituted one from the
collection. Javac issues compilation errors when compiling Java code against
such classes.

Also all the needed method stub signatures were hardcoded in
generateBuiltInMethodStubs() and the case of MutableListIterator was missing
2014-10-27 17:17:31 +03:00
Alexander Udalov
fb5806f5fb Fix inheritance from mutable Java collections
Don't use CodegenUtil#getDeclaredFunctionByRawSignature because it's incorrect
in case of platform types. Instead use JetTypeMapper to find JVM signatures of
methods which are callable on the current class

 #KT-6042 Fixed
2014-10-22 10:51:14 +04:00
Alexander Udalov
4968afebf8 Don't generate bodies of built-in stub methods into interfaces 2014-02-24 21:44:42 +04:00
Evgeny Gerashchenko
d56c59d9d7 Removed toArray() from collections (few tests are still failing).
#KT-3352 in progress
2013-10-01 15:11:30 +04:00
Evgeny Gerashchenko
b4bb08c013 Generating stub methods for read-only map and entry. 2013-09-25 20:59:24 +04:00
Evgeny Gerashchenko
511c908ba9 Generating stub methods for read-only collection. 2013-09-25 20:59:24 +04:00
Evgeny Gerashchenko
5de9c2499d Added for iterator when remove() is present. 2013-09-25 20:59:23 +04:00
Evgeny Gerashchenko
47b70427e1 Generating remove() for Iterator using same mechanism. 2013-09-25 20:59:23 +04:00
Evgeny Gerashchenko
b4368ad578 Generating stub methods for read-only list. 2013-09-25 20:59:23 +04:00