Commit Graph

18883 Commits

Author SHA1 Message Date
Alexander Udalov 8dae1b62dd Add CharSequence.subSequence
This is done primarily for JVM interoperability, otherwise it's impossible to
inherit from CharSequence there. On JS subSequence at the moment just invokes
substring.

 #KT-5956 Fixed
2014-11-27 20:38:19 +03:00
Alexander Udalov 4d95bcfc7e Rename CharSequence.get to charAt
This is done for JVM interoperability. There's still a member function
String.get() and an extension function "get" on CharSequence

 #KT-1730 Fixed
 #KT-5389 Fixed
2014-11-27 20:38:18 +03:00
Alexander Udalov a7b88e9485 Make CharSequence.length a function instead of property
And String.length as well.

This is done for JVM interoperability: java.lang.CharSequence is an open class
and has a function 'length()' which should be implemented in subclasses
somehow.

A minor unexpected effect of this is that String.length() is now a compile-time
constant (it wasn't such as a property because properties are not supported in
compile-time constant evaluation)

 #KT-3571 Fixed
2014-11-27 20:38:17 +03:00
Alexander Udalov 6b8da062a4 Increase memory for 'All * Tests' configurations
Use the same parameters as for All Tests
2014-11-27 20:38:17 +03:00
Denis Zharkov 3b2d0b88f3 Supported nested reified parameter declarations
Also switched to using type names as identifiers instead of their
indices
2014-11-27 15:15:04 +04:00
Denis Zharkov 080610c208 Wrap parentCodegen before generating from inline 2014-11-27 14:58:04 +04:00
Denis Zharkov 538a2172e5 Got rid of hack with stashing wereReified
1. Made ClosureCodegen extending MemberCodegen
2. Made ClosureContext extending ClassContext
2014-11-27 14:58:04 +04:00
Denis Zharkov ca27be87cc Minor, removed redundant argument
from ClassBodyCodegen.generateDeclaration
2014-11-27 13:49:18 +04:00
Denis Zharkov 37d476c388 Moved DiagnosticFactories about reified to
``Type parameter declarations'' block
2014-11-27 13:49:18 +04:00
Denis Zharkov 02be1063c1 Do not report a warning on an inline function with a reified parameter
#KT-6273 Fixed
2014-11-27 13:49:17 +04:00
Denis Zharkov f7d1bc5931 Diagnostics test: array creation of non-reified TP
#KT-1370 Fixed
2014-11-27 13:49:17 +04:00
Evgeny Gerashchenko 428109e8c4 Updated regexp for Windows. Hope it fixes test on buildserver... 2014-11-27 12:22:15 +03:00
Svetlana Isakova 724f2e6e7b KT-6081 Chained generic method calls: wrong type inference
#KT-6081 Fixed
2014-11-27 02:28:10 +03:00
Evgeny Gerashchenko 9c880de735 Compilation errors are rendered to log without "Kotlin:ERROR:" prefix and without path to file. Sometimes javac adds path to file, sometimes doesn't. This had led tests to fail on some platforms. 2014-11-26 18:42:24 +03:00
Alexander Udalov 8cb1c7f0e6 Pass NameResolver to loadClassAnnotations()
It's not used at the moment, but will be in the upcoming implementation of
annotation loader (for JS, built-ins and type annotations)
2014-11-26 17:27:08 +03:00
Evgeny Gerashchenko 19ad2406ff Moved test data into common directory. 2014-11-26 14:32:12 +03:00
Evgeny Gerashchenko adcd4d4ca0 Fixed case of file name. 2014-11-26 14:32:11 +03:00
Alexey Sedunov 591c409854 Change Signature: Process Kotlin-based usages when changing signature of the Java function 2014-11-26 13:07:38 +03:00
Alexey Sedunov 18c10c9079 Change Signature: Allow running Java change signature from Kotlin usage/override 2014-11-26 13:07:37 +03:00
Alexey Sedunov b5f2ce743c Change Signature: Allow running Kotlin change signature from Java usage/override 2014-11-26 13:07:36 +03:00
Alexey Sedunov 3d2cc129b5 Change Signature: Allow running Java's Change Signature in tests 2014-11-26 13:07:35 +03:00
Alexey Sedunov 5c4dd75110 Light Methods: Change PSI element language to Kotlin 2014-11-26 13:07:34 +03:00
Alexey Sedunov 1008225116 Change Signature: Processing of non-Kotlin usages
#KT-5810 Fixed
 #KT-4187 Fixed
2014-11-26 13:07:33 +03:00
Alexey Sedunov c35c4072c6 Change Signature: Add support of multi-file tests 2014-11-26 13:07:32 +03:00
Alexey Sedunov c80c866d82 Change Signature: Rename parameter in overriding functions
#KT-4045 Fixed
2014-11-26 13:07:31 +03:00
Alexey Sedunov ddccc0e640 Change Signature: Update enum entries w/o delegation specifier when changing signature of enum class constructor
#KT-5978 Fixed
2014-11-26 13:07:29 +03:00
Alexey Sedunov 5bfdb8ee60 Change Signature: Do not add default values to parameters of overriding functions
#KT-6160 Fixed
2014-11-26 13:07:28 +03:00
Alexey Sedunov d597c98445 Extract Function: Fix NPE when extracting this in object
#KT-6238 Fixed
2014-11-26 13:07:27 +03:00
Alexander Udalov e0c842b3d8 Convert BuiltInsSerializationUtil to Kotlin 2014-11-25 23:17:01 +03:00
Alexander Udalov a6d759ff96 Minor, add test for obsolete issue
#KT-3587 Obsolete
2014-11-25 23:16:56 +03:00
Alexander Udalov 7d43f39c80 Fix disappearing exceptions in GenerateProtoBuf.kt
Any exception caught during the generation (e.g. about an incompatible version)
is lost because of 'System.exit(0)' in 'finally'
2014-11-25 23:16:28 +03:00
Alexander Udalov 4e735878cf Minor, add "storageManager" property to context for convenience 2014-11-25 23:16:28 +03:00
Alexander Udalov c35ddc3616 Minor, make ownTypeParameters a property in TypeDeserializer 2014-11-25 23:16:28 +03:00
Alexander Udalov 3a066dfd07 Rename "context" -> "c" in deserialization for brevity 2014-11-25 23:16:27 +03:00
Alexander Udalov 1c04a6052f Get rid of unnecessary list in Interner 2014-11-25 23:16:27 +03:00
Alexander Udalov 1f68c94ce6 Fix several bugs in serialization of inner generic classes
- Interner was working incorrectly with parents
- nested classes were serialized in codegen out of any context

 #KT-5660 Fixed
2014-11-25 23:16:26 +03:00
Alexander Udalov 36c65e4264 Minor, drop strange method from SerializerExtension 2014-11-25 23:16:26 +03:00
Alexander Udalov b56076bd6a Merge LazyJavaResolverContext and LazyJavaResolverContextWithTypes 2014-11-25 23:16:26 +03:00
Alexander Udalov 60662e5831 Fix double laziness of annotations introduced in 149a90d 2014-11-25 23:16:21 +03:00
Alexander Udalov 75851d44cc Minor, inline method from LazyJavaPackageFragmentProvider 2014-11-25 23:15:50 +03:00
Alexander Udalov ab6fec1540 Simplify type deserializer construction even more 2014-11-25 23:15:50 +03:00
Alexander Udalov 2b189c5193 Convert TypeDeserializer to Kotlin 2014-11-25 23:15:49 +03:00
Alexander Udalov c9bef09085 Extract DeserializedType to top level and convert to Kotlin 2014-11-25 23:15:49 +03:00
Alexander Udalov 07c3a07ecb Make DeserializedType a static nested class 2014-11-25 23:15:49 +03:00
Alexander Udalov 5907df92db Drop secondary DeserializedPackageMemberScope constructor
Create package context only once
2014-11-25 23:15:49 +03:00
Alexander Udalov e1a1c06c3e Rename deserialization context for Java to "components"
Simplify its injection to DeserializedDescriptorResolver
2014-11-25 23:15:49 +03:00
Alexander Udalov 823009e0df Add laziness-friendly toString() to lazy type parameter 2014-11-25 23:15:48 +03:00
Alexander Udalov a4d4d15ca9 Improve code after conversion, fix some warnings 2014-11-25 23:15:48 +03:00
Alexander Udalov d3635de205 Convert MemberDeserializer to Kotlin 2014-11-25 23:15:48 +03:00
Alexander Udalov 9c80801c3a Rename MemberDeserializer.java -> .kt 2014-11-25 23:15:48 +03:00