Commit Graph

13080 Commits

Author SHA1 Message Date
Denis Zharkov 495780f5ab Generate INVOKEVIRTUAL 'contains(Object)' instead of 'contains(String)'
In cases when callee overrides Collection<String>.contains
2015-10-16 18:16:02 +03:00
Denis Zharkov 64da399b31 Do not generate builtin bridges with Kotlin signature as synthetic
They should be available in Java (at least for overridding)
2015-10-16 18:16:02 +03:00
Denis Zharkov d335f71dfe Generate special bridges for builtins with same name but different JVM descriptor 2015-10-16 18:16:02 +03:00
Denis Zharkov 07d8754adb Minor. Add bytecode listing tests with contains* methods 2015-10-16 18:16:02 +03:00
Denis Zharkov b5296104e9 Ignore fake overrides when generating stub methods for MutableCollections
Because it's redundant as we go through all mutable collection hierarchy anyway
It wasn't a problem because for fake override just `generatedBridges` is being called
and there were no special bridges for such methods.
2015-10-16 18:16:02 +03:00
Denis Zharkov 65551e1185 Print 'final' and 'abstract' in BytecodeListing tests and sort declarations
Latter is needed to make format stable
2015-10-16 18:16:02 +03:00
Denis Zharkov 978a4cfa3c Minor. Refine naming for SpecialBuiltinMembers 2015-10-16 18:16:02 +03:00
Denis Zharkov bd37a10677 Transform *Array.size to properties 2015-10-16 18:16:02 +03:00
Andrey Breslav b050324869 Mark string prefixes and suffixes as unsupported 2015-10-16 18:03:53 +03:00
Andrey Breslav 267ec2724e Minor. Ant task renamed: JetLexer -> KotlinLexer 2015-10-16 17:55:12 +03:00
Andrey Breslav d1a3a66e12 Minor. Comments removed 2015-10-16 17:55:11 +03:00
Nikolay Krasko cf7f94a559 Process request for searching class with empty qualified name without errors 2015-10-16 16:28:02 +03:00
Yan Zhulanow 2a55894bec Update OperationsMapGenerated 2015-10-16 16:19:51 +03:00
Zalim Bashorov 79d38a6c8f Report the error when a declaration in Kotlin accidentally overrides a static member from Java 2015-10-16 16:14:34 +03:00
Zalim Bashorov 72a686f9e0 Add tests for accessing to Java/Kotlin inner/nested classes 2015-10-16 16:09:35 +03:00
Zalim Bashorov 9acf3e40de Generic type with Nothing in arguments compiles to raw type 2015-10-16 15:30:41 +03:00
Michael Nedzelsky 8e9f1ac31a Extension function type is not allowed as supertype 2015-10-16 14:23:47 +03:00
Dmitry Petrov 670b49ec5e Dropping package facades: remove unused imports from package facades
(not cleaned up automatically)
2015-10-16 11:23:22 +03:00
Alexander Udalov f62128bdcd Fix protobuf extension API usages
"getExtension" returns default value when the requested extension is not
present, which is 0 for Int, which makes no sense for extensions like
methodImplClassName that are storing the number in the string table
2015-10-15 22:36:22 +03:00
Michael Nedzelsky 114d19e6d9 use MainFunctionDetector in order to check for main function 2015-10-15 19:24:45 +03:00
Valentin Kipyatkov f67bd8c13f Even more precise keyword completion for modifiers 2015-10-15 19:20:11 +03:00
Valentin Kipyatkov 762900037e Minor 2015-10-15 19:20:11 +03:00
Valentin Kipyatkov 26768ad34b Renames 2015-10-15 19:20:11 +03:00
Valentin Kipyatkov 292ea7625c Removed obosolete modifier "ref" from tests 2015-10-15 19:20:11 +03:00
Valentin Kipyatkov dfcf459bf6 Minor 2015-10-15 19:20:11 +03:00
Valentin Kipyatkov 87cfccc2d9 Removed all places in parser where obsolete annotation syntax was allowed 2015-10-15 19:20:10 +03:00
Valentin Kipyatkov 875eaa52e3 Removing unused code 2015-10-15 19:20:10 +03:00
Valentin Kipyatkov 434be3be21 Adapted keyword completion to changed parser + more precise completion for modifier keywords 2015-10-15 19:20:09 +03:00
Valentin Kipyatkov 090ea37a32 Fixed test data to use only annotation syntax with @ 2015-10-15 19:20:08 +03:00
Valentin Kipyatkov 487501a7a4 Fixed test data after changes in parser 2015-10-15 19:20:08 +03:00
Valentin Kipyatkov d84020b1f3 Removed special support for parsing annotations for multi-declaration in for 2015-10-15 19:20:08 +03:00
Valentin Kipyatkov 98dc8f234e Drop suppport for annotation syntax without '@' from parser 2015-10-15 19:20:07 +03:00
Alexander Udalov 66417ed329 Parse type arguments after callable reference as error
Is likely to be supported in the future
2015-10-15 18:25:42 +03:00
Alexander Udalov bf4a681589 Deduce receiver type of callable reference from LHS, not from descriptor 2015-10-15 18:25:42 +03:00
Alexander Udalov 2cf437c0e2 Fix type of callable reference to fake override 2015-10-15 18:25:41 +03:00
Alexander Udalov 9eb2e16b94 Support strings directly in JVM string table
For small strings it may be beneficial to store them as is in the proto at one
point instead of in a class annotation, because each annotation argument in the
classfile has a constant overhead which may be significant for small strings
2015-10-15 18:25:41 +03:00
Alexander Udalov 4c21142648 Store type parameter names sometimes instead of ids
This helps to reuse instances of types when TypeTable is enabled in cases when
a file or a class contains a lot of functions with type parameters with the
same name (like Maps.kt in the stdlib with "Map<K, V>")
2015-10-15 18:25:40 +03:00
Alexander Udalov fb5d8de84b Use type table in DescriptorSerializer, add switch to enable/disable, test 2015-10-15 18:25:40 +03:00
Alexander Udalov 82d2e623d3 Support a more optimized way of storing types in metadata
Together with almost every type now there's also an id which references a type
from a separate table. Storing such ids instead of Type messages will allow to
reduce the size of the metadata for files where types are used many times over
and over again. Currently only deserialization of such types is supported,
along with the former mechanism
2015-10-15 18:25:39 +03:00
Yan Zhulanow bff6639e2d Use stubs in checkParameterInFunctionType 2015-10-15 18:23:58 +03:00
Yan Zhulanow d52f245cf7 Rename unary plus/minus in builtins and stdlib 2015-10-15 18:23:58 +03:00
Yan Zhulanow f7ce0c2d20 Add new intrinsic methods: unaryPlus, unaryMinus 2015-10-15 18:23:58 +03:00
Ilya Gorbunov c4ef4758d2 Remove last two usages of Delegates.blockingLazy 2015-10-15 18:20:39 +03:00
Pavel V. Talanov d9ed79e781 Add test for not generating file facade light class for empty file 2015-10-15 15:49:46 +03:00
Pavel V. Talanov 9e9f593a7f Generate tests for ide light classes from the same test data as for compiler light classes 2015-10-15 15:49:45 +03:00
Pavel V. Talanov 35e56993d3 Rename: KotlinLightClassTest -> CompilerLightClassTest
In fact we have very different code in compiler and ide but only one test
2015-10-15 15:49:44 +03:00
Pavel V. Talanov 53b21061fd Don't use StubBasedPsiElementBase#getStubOrPsiParent
#KT-9579 Fixed
2015-10-15 15:49:42 +03:00
Pavel V. Talanov bfcabad148 Don't override StubBasedPsiElementBase.getStub
#KT-9575 Fixed
2015-10-15 15:49:42 +03:00
Michael Nedzelsky 890ae3e914 Make single-file classes tolerant to having many main()'s 2015-10-15 15:46:26 +03:00
Dmitry Petrov 8cd624a58a Drop package facades: code cleanup in Kotlin project. 2015-10-15 10:33:47 +03:00