Commit Graph

2173 Commits

Author SHA1 Message Date
Alexander Udalov baaa3ef50a Remove KotlinSignature annotations from project code 2015-10-13 20:29:16 +03:00
Alexander Udalov b378969a0a Deprecate KotlinSignature, to be removed later 2015-10-13 20:29:15 +03:00
Mikhail Glukhikh 5a16e43579 Synchronized is no more allowed on abstract functions 2015-10-13 16:37:34 +03:00
Mikhail Glukhikh ccf0c363fa Volatile is no more allowed on values #KT-7670 Fixed 2015-10-13 16:37:24 +03:00
Mikhail Glukhikh 8473be357f Effective visibility: separate InternalProtected and InternalProtectedBound, messages, test change 2015-10-13 16:31:28 +03:00
Mikhail Glukhikh 4dbd7e7f69 Effective visibility: lower bounds introduced for all protected and for protected and internal #KT-9540 Fixed 2015-10-13 16:26:05 +03:00
Andrey Breslav dbc0197a36 @HiddenDeclaration deprecated 2015-10-13 13:50:16 +03:00
Andrey Breslav 8e7f6f3c8c Migrated from @HiddenDeclaration to @Deprecated(..., level = DeprecationLevel.HIDDEN) 2015-10-13 13:50:16 +03:00
Alexander Udalov 5f18cb8703 Rename files in reflection.jvm
Move KDeclarationContainer.functions to KClasses and make it accept only
KClass, since KPackage is deprecated anyway
2015-10-13 11:58:45 +03:00
Michael Bogdanov a09c8105c4 Support reflection on top level properties 2015-10-13 11:14:33 +03:00
Michael Bogdanov e8f9a9f3b8 Support reflection on @JvmField properties inside class companion 2015-10-13 11:14:32 +03:00
Michael Bogdanov f4b7913dd3 sanitizeAsJavaIdentifier function moved to JvmAbi 2015-10-13 11:14:32 +03:00
Michael Bogdanov b713328540 Fix reflection for internal properties without getter/setter 2015-10-13 10:50:10 +03:00
Andrey Breslav 1c00b933a5 @Deprecated(..., level = HIDDEN) supported
isAnnotatedAsHidden() moved to front-end
2015-10-13 01:44:46 +03:00
Dmitry Petrov ff1bf673ba Java 8 override restrictions: interface can't implement a method of 'Any'
- update Range and related classes
2015-10-12 14:12:31 +03:00
Dmitry Petrov 7e9e427d4c Java 8 rules for method overrides:
- report errors on implementing methods of Any in interfaces
- update testData

~~~

Java 8 override restrictions: interface can't implement a method of 'Any'
- update compiler sources
2015-10-12 14:12:31 +03:00
Dmitry Jemerov 1523d5bcbf removing static type assertions work in progress 2015-10-12 11:11:23 +02:00
Denis Zharkov 6d864e0854 Adjust collection stubs generating to 'remove' transformation
See substitutedList* tests in Backend
2015-10-11 19:59:30 +03:00
Denis Zharkov 89ded4ab1d Implement hack to support both remove() and removeAt() in MutableList<Int>
Also add couple of tests about CharSequence.get
2015-10-11 19:57:22 +03:00
Denis Zharkov 742a538aed Support loading builtin methods from Java with different names 2015-10-11 19:57:22 +03:00
Denis Zharkov 3f5498e9f5 Transform some builtin methods
1. CharSequence.charAt -> get
2. ML.remove(Int) -> removeAt,
3. MC.remove(Any?) -> MC.remove(E)
2015-10-11 19:57:21 +03:00
Denis Zharkov a98d1e1e55 Minor. Convert some properties to functions 2015-10-11 19:57:08 +03:00
Alexander Udalov 9d626ef1d9 Rename KotlinCallable annotation to KotlinFunction 2015-10-11 17:10:40 +03:00
Alexander Udalov d4320b43fa Delete useless class, simplify reading class visitor 2015-10-11 17:10:38 +03:00
Alexander Udalov 9e4823ef82 Write module name to metadata, fix reflection for file facades
Module name will be used for proper introspection of internal members
2015-10-11 17:10:37 +03:00
Alexander Udalov 0218e0351b Deprecate KPackage, to be removed later 2015-10-11 17:10:37 +03:00
Alexander Udalov 790c59d9e5 Increase ABI & stub version
See previous commits for motivation
2015-10-11 17:10:36 +03:00
Alexander Udalov 37c36f806a Rename foreignKotlinClass -> getOrCreateKotlinClass
Previously this cache contained only Java (hence 'foreign') classes, that is
not the case anymore
2015-10-11 17:10:35 +03:00
Alexander Udalov a4732b442d Don't create KClass and KPackage instances in <clinit>
This proved to be a fragile technique, which probably doesn't even improve
performance in most cases but has lots of unexpected problems: unconditional
initialization of reflection classes, increasing the size of the bytecode, bugs
with <clinit> in annotations on JVM 6, inability to support conversion of a
class from Kotlin to Java without recompiling clients which use it
reflectively, etc.
2015-10-11 17:10:35 +03:00
Alexander Udalov fe737886cd Drop deprecated K*Function interfaces 2015-10-11 17:10:34 +03:00
Alexander Udalov 8c4d7fdf24 Drop deprecated nested classes from Kotlin metadata annotations 2015-10-11 17:10:33 +03:00
Alexander Udalov 1c229d173e Forget old classes from jet.runtime.typeinfo.*, drop JetValueParameter 2015-10-11 17:10:32 +03:00
Alexander Udalov e3a5590eb7 Simplify FQ name check in ReflectionTypes
Fix EA-73058
2015-10-11 17:10:32 +03:00
Alexander Udalov 934ffed944 Don't write field signatures when not necessary 2015-10-11 17:10:30 +03:00
Alexander Udalov 864926ee2e Don't always write JVM method signatures to metadata
When the trivial type mapping (implemented in JvmProtoBufUtil) from
ProtoBuf.Type instances works fine, don't write the signature since it can be
loaded by exactly the same trivial type mapping
2015-10-11 17:10:30 +03:00
Alexander Udalov 3506a9615e Don't write default values of flags, provide sensible defaults 2015-10-11 17:10:28 +03:00
Alexander Udalov e58677b8fe Do not fail on unknown visibilities, modalities, etc in deserialization
Provide some sensible defaults like "private", "final", "class" instead, which
will give us a small possibility to not break the format if a new
modality/visibility/... is introduced in the case when the old compiler may
safely consider it as the default one
2015-10-11 17:10:28 +03:00
Alexander Udalov 2e10d21e3f Minor, rename LATE_INIT -> IS_LATEINIT, INNER -> IS_INNER 2015-10-11 17:10:27 +03:00
Alexander Udalov aa95375029 Fix incorrect copy-paste during proto messages refactoring
Annotations on properties should be loaded not when the message is Property
(this happens for getters/setters as well), but when the kind is explicitly set
to PROPERTY. Also restore construction of JVM signatures for constructors
2015-10-11 17:10:26 +03:00
Alexander Udalov e4efa27b76 Drop Callable and primary/secondary constructor proto messages 2015-10-11 17:10:26 +03:00
Alexander Udalov a44f74ea20 Load new proto messages for constructors 2015-10-11 17:10:24 +03:00
Alexander Udalov 9bf0502a31 Load new proto messages for functions and properties 2015-10-11 17:10:24 +03:00
Denis Zharkov cfc9d19825 Transform Collection.isEmpty and Map.Entry.key/value to properties 2015-10-10 12:29:14 +03:00
Denis Zharkov ad68378836 Support loading methods from Java as common properties overrides 2015-10-10 12:29:14 +03:00
Yan Zhulanow ed5c059cea Rename unary plus() and minus() to unaryPlus() and unaryMinus() 2015-10-09 22:49:17 +03:00
Yan Zhulanow 1f2b4e20fe Replace get() and set() to getValue() and setValue() (property delegates) 2015-10-09 22:49:16 +03:00
Valentin Kipyatkov 7b2d63cfb9 Added infix modifier 2015-10-09 16:42:07 +03:00
Michael Bogdanov a3e0205aec JvmAbi increased 2015-10-09 16:25:19 +03:00
Michael Bogdanov 60d1736b97 Instance field generation in objects 2015-10-09 16:25:16 +03:00
Michael Bogdanov 53ced57c42 Annotations.EMPTY replaced with Annotations.Companion.getEMPTY() in java classes 2015-10-09 16:25:15 +03:00