Denis Zharkov
b2cecf1dd0
Secondary constructors resolve
2015-03-11 17:45:23 +03:00
Denis Zharkov
8305d73682
Drop unused interface method
...
There was the only usage and it's redundant.
JetClass' implementation name is refined.
2015-03-11 17:45:22 +03:00
Denis Zharkov
3ba94d7352
Parsing: secondary constructors
2015-03-11 17:45:22 +03:00
Denis Zharkov
cb881d2628
Drop some ClassDescriptor.getConstructors() usages
...
supposing that there is only primary constructor
2015-03-11 17:45:22 +03:00
Denis Zharkov
bdd2756bd1
Rename ThisReference -> ConstructorDelegationReference
2015-03-11 17:45:22 +03:00
Denis Zharkov
a55e8911ea
Drop parsing of enum initializers using `this'
...
#KT-6626 Fixed
2015-03-11 17:45:22 +03:00
Alexander Udalov
dc4dfbeec1
Fix generic class literals, substitute type parameters with stars
2015-03-11 16:42:47 +03:00
Alexander Udalov
6468515d99
Report error when LHS of class literal is not a class
2015-03-11 16:42:45 +03:00
Alexander Udalov
b93b9bd565
Support KClass.simpleName and built-in class literals
2015-03-11 16:42:43 +03:00
Alexander Udalov
6e45c6f17c
Support class literals (A::class)
2015-03-11 16:42:41 +03:00
Alexander Udalov
2b089e0f39
Configure kotlin-reflect.jar in IDE as part of KotlinJavaRuntime library
2015-03-11 16:42:39 +03:00
Alexander Udalov
b3cdd818f0
Support member extension properties, implement KClass.getExtensionProperties()
...
#KT-6570 Fixed
2015-03-11 16:42:38 +03:00
Alexander Udalov
da209e673c
Implement KClass.getProperties()
...
#KT-6570 In Progress
2015-03-11 16:42:37 +03:00
Alexander Udalov
fdfd808d80
Remove KForeignMemberProperty and KClassOrigin, use KMemberPropertyImpl instead
2015-03-11 16:42:36 +03:00
Alexander Udalov
ff0044f66a
Use descriptors for reflection on extension properties
2015-03-11 16:42:34 +03:00
Alexander Udalov
1a618deeab
Use descriptors for reflection on top level properties
...
This also allows to obtain a Field object from the package part (see
mapping.kt)
2015-03-11 16:42:33 +03:00
Alexander Udalov
64fdb18ad3
Use descriptors for reflection on class properties
...
- use ConcurrentHashMap as a cache of class loaders to module descriptors
- KClassImpl now has a lazy class descriptor and it manages property creation
by looking (also lazily) for the property descriptor in the corresponding
scope
- since deserialized descriptors have full information about where a JVM symbol
is located and what signature it has, new tests will begin to pass where
Kotlin model and Java reflection model differ, see classObjectVar.kt
2015-03-11 16:42:31 +03:00
Alexander Udalov
2b090e02a1
Build kotlin-reflect.jar in build.xml and for Maven
...
Reflection will be distributed in a separate jar and not in kotlin-runtime.jar
for two primary reasons:
- Reflection implementation at the moment takes almost 2Mb
- Separate libraries for separate features is a technique encouraged by Maven,
and it's inconvenient to make it different in the compiler distribution
2015-03-11 16:42:28 +03:00
Alexander Udalov
e95d22dcfe
Refactor ReflectJavaConstructor.getValueParameters()
...
See https://youtrack.jetbrains.com/issue/KT-6886 for more information
2015-03-11 16:42:25 +03:00
Alexander Udalov
1054f004aa
Load annotations on constructors and parameters of Kotlin reflected classes
2015-03-11 16:42:24 +03:00
Alexander Udalov
4fb420f3f1
Fix deserialization of enum annotation arguments at runtime
2015-03-11 16:42:23 +03:00
Alexander Udalov
a14b301f31
Resolve annotations on all reflected elements
...
Annotation in NestedEnumArgument test is made public, because we try to load
annotation argument values eagerly and fail, since you can't invoke methods
reflectively on an object of a non-effectively-public class
2015-03-11 16:42:19 +03:00
Alexander Udalov
c90f11b7e6
Support Java symbols in runtime descriptor loading
2015-03-11 16:42:18 +03:00
Alexander Udalov
73e4287aee
Initial support of annotation loading at runtime
...
In order to locate an annotated entity, we need to implement almost the whole
Java element model (which will be used anyway for Java descriptor loading)
2015-03-11 16:42:17 +03:00
Alexander Udalov
356f54b5df
Initial support of descriptor loading at runtime
2015-03-11 16:42:15 +03:00
Dmitry Jemerov
07381b765f
rename Numbers.kt to Primitives.kt as it now contains Char which is not a number
2015-03-11 12:40:39 +01:00
Dmitry Jemerov
26e452383e
reenable test which was temporarily disabled
2015-03-10 20:28:48 +01:00
Pavel V. Talanov
81f9d34d1a
Add quick fix for deprecated 'class object' syntax
2015-03-10 18:21:33 +03:00
Pavel V. Talanov
581e163031
Report warning on 'class object'
2015-03-10 18:21:32 +03:00
Pavel V. Talanov
9a844d2feb
Minor: replace some missed mentions of 'class object' with 'default object'
2015-03-10 18:07:54 +03:00
Pavel V. Talanov
9ecf95532e
Replace 'class object' with default object in project code
2015-03-10 18:07:46 +03:00
Natalia Ukhorskaya
f6162dc726
JetCodeFragment: increment modification count after inserting import
2015-03-10 15:27:37 +03:00
Alexander Udalov
a8046020fb
Rename kotlin.reflect.IllegalAccessException -> IllegalPropertyAccessException
...
The former name clashes with java.lang.IllegalAccessException and proved to be
inconvenient because it should always be qualified in the source.
Also use java.lang exception's message as kotlin.reflect exception's message
2015-03-07 02:32:15 +03:00
Alexander Udalov
ed022f892b
Drop JavaTypeParameter#getIndex
2015-03-07 02:32:14 +03:00
Alexander Udalov
ca8831097f
Resolve annotations on Java constructors
...
Also add tests on custom annotations on fields and methods
2015-03-07 02:32:14 +03:00
Alexander Udalov
17c21dcaa2
Test generator: allow to exclude certain test data directories
2015-03-07 02:32:14 +03:00
Alexander Udalov
0bd5264b5e
Get rid of module reflection.stub.jvm
...
Generate K*Function as a supertype for a function reference instead of
K*FunctionImpl; this will allow one binary library to be used with or without
reflection
2015-03-07 02:31:26 +03:00
Alexander Udalov
eced3003ad
Introduce kotlin-reflect Maven artifact
2015-03-07 02:31:00 +03:00
Andrey Breslav
dcfa77c77d
completeAnalysisNeeded() removed
2015-03-06 21:59:05 +03:00
Andrey Breslav
bbb59773aa
filesToAnalyzeCompletely removed
2015-03-06 21:59:05 +03:00
Andrey Breslav
456bbb6b96
Logically missing method added
2015-03-06 21:59:05 +03:00
Andrey Breslav
1c8af2d2fe
Rename. LocalClassDescriptorManager -> LocalClassDescriptorHolder
2015-03-06 21:59:04 +03:00
Andrey Breslav
253d76669d
resolveMutableClassDescriptor() removed
2015-03-06 21:59:04 +03:00
Andrey Breslav
b567356702
Unused code removed from TopDownAnalysisContext
2015-03-06 21:59:04 +03:00
Andrey Breslav
32a3b58f14
ScriptDescriptorImpl and related non-lazy code removed
2015-03-06 21:59:04 +03:00
Andrey Breslav
7d1a826778
Rename. LazinessToken -> TypeLazinessToken
2015-03-06 21:59:04 +03:00
Andrey Breslav
30a84a2bd8
Uneeded usages of LazinessToken.isLazy() are removed
2015-03-06 21:59:03 +03:00
Andrey Breslav
d310b0c99d
Got rid of the LAZY flag
2015-03-06 21:59:03 +03:00
Andrey Breslav
d466533ef2
Missing test added
2015-03-06 21:59:03 +03:00
Alexey Tsvetkov
b280e891e9
JS: read compiled js modules
2015-03-06 21:36:18 +03:00