dnpetrov
f364d23ee9
KT-5347 VerifyError on local data class with closure
...
- generated copy() should push captured fields on stack
- refactor context lookup
- handle vars in local classes using instance fields
#KT-5347 Fixed
2015-06-25 17:52:30 +03:00
dnpetrov
c24e6b5698
Support 'break' and 'continue' in expressions
...
- generate fake jump instructions so that we can always analyze stack depths
- fix stack before break and continue by dropping excessive elements (e.g., *a*.foo(*b*, c?:continue))
- Analyzer rewritten in Kotlin, with more flexible control of CFG traversal
#Fixed KT-3340
#Fixed KT-4258
#Fixed KT-7941
2015-06-25 17:40:55 +03:00
Mikhail Glukhikh
5fabb962ae
Private constructors are now accessed via synthetic constructor with DEFAULT_CONSTRUCTOR_MARKER as an additional argument #KT-6299 Fixed
...
A set of tests provided. Some external tests fixed accordingly.
Companion object creation changed accordingly.
Derived classes now can use base class with the private constructor.
Refactoring of AccessorForFunctionDescriptor.
2015-06-24 12:30:11 +03:00
Michael Bogdanov
9ef00f0621
Code clean
2015-06-24 09:48:56 +03:00
Michael Bogdanov
b1c5002889
Remove finally marker at inlining
2015-06-24 09:48:55 +03:00
Michael Bogdanov
a018e4e12a
Updated exception table generation: support new exception table in non-local returns
2015-06-24 09:48:55 +03:00
Michael Bogdanov
93c5a52d13
Updated exception table generation: try block return moved to uncatched interval
...
#KT-8148 Fixed
2015-06-24 09:48:55 +03:00
Yan Zhulanow
fee1726dfb
Write annotations with RetensionPolicy(SOURCE) to light classes
2015-06-19 02:25:41 +03:00
dnpetrov
36ae8790a1
KT-8011 Compiler crashes on attempt to create local class inside lambda
...
- use StackValue from upper-level context if local lookup fails
#KT-8011 Fixed
2015-06-18 17:40:24 +03:00
Alexander Udalov
1a3209e1dc
Drop traits with required classes
...
#KT-4771 Rejected
2015-06-17 16:23:58 +03:00
Alexander Udalov
8207e08c61
Convert TraitImplBodyCodegen to Kotlin
2015-06-17 16:23:57 +03:00
Alexander Udalov
98ce0d529c
Fix incorrect 'original' in property accessors
...
#KT-3930 Fixed
2015-06-17 16:23:56 +03:00
Alexander Udalov
7c846388bd
Remove some unreachable/duplicated code in StackValue
2015-06-17 16:23:56 +03:00
Alexander Udalov
4dcc373a5a
Fix concrete method inheritance in interfaces
...
For each non-abstract non-declared (i.e. inherited from supertypes) method in
an interface we generate its static form to the TImpl, which calls the TImpl
method from the corresponding supertype.
The accidental override tests changed because we're now trying to generate the
delegate for the super method, not knowing that it will clash with the declared
method
#KT-2888 Fixed
#KT-5393 Fixed
2015-06-17 16:23:56 +03:00
dnpetrov
c369949d90
KT-6136 VerifyError on data class inheriting from trait
...
- coerce property values to proper data class component types
- add tests
#KT-6136 Fixed
2015-06-16 09:58:03 +03:00
Denis Zharkov
eb7114bd53
Add 'constructor' keyword in whole project where needed
2015-06-12 09:55:15 +03:00
Denis Zharkov
d71fe0d11a
Drop JavaClassValue and it's usages
...
Also drop related testData
2015-06-12 09:55:10 +03:00
Denis Zharkov
200dee2761
Replace deprecated annotations in whole project
2015-06-12 09:23:32 +03:00
Alexey Sedunov
1ea2c24562
Light Classes: Primary constructor fixes
2015-06-11 13:52:48 +03:00
Natalia Ukhorskaya
1ed9ea44a9
Line numbers for traits
2015-06-11 12:10:16 +03:00
Michael Bogdanov
baa44e3d01
Fix default parameter remapping on inlining: support store instruction
...
#KT-7963 Fixed
2015-06-08 16:07:39 +03:00
Michael Bogdanov
7a1625fc9e
Support extension lambda inlining
...
#KT-7962 Fixed
2015-06-08 16:07:38 +03:00
Alexander Udalov
9e8c51f7d3
Minor, delete pointless field annotations
2015-06-04 23:08:20 +03:00
dnpetrov
50ea67ba13
KT-5524 Support [platformName] annotation for class members
...
@platformName is now supported for final non-overriding class member functions
(including property accessors).
Front-end provides diagnostics for inapplicable annotation cases.
Code generation updated:
- ignore kotlin.platform.platformName annotation for Java class methods;
- bridges generation generates proper JVM declarations in case of methods renamed with @platformName.
@platformName-related tests added.
#KT-5524 Fixed
2015-06-04 17:54:08 +03:00
Evgeny Gerashchenko
6403ef39eb
KT-7521 Compilation problem of dependent modules with different jdks
...
#KT-7521 fixed
2015-06-04 17:50:13 +03:00
Denis Zharkov
9802931a90
Remove variables with empty ranges from local vars table
...
As their ranges may intersect after dead code elimination that leads to VerifyError
2015-06-04 16:11:02 +03:00
Denis Zharkov
310babefdf
Minor, Rename InsnStream -> InsnSequence
2015-06-04 16:11:02 +03:00
Denis Zharkov
8da3f53404
EA-53937: Drop failing assertion about no-name val in annotation
2015-06-04 16:11:02 +03:00
Michael Bogdanov
2377a10007
Fix labeling processing on inlining: suport labeled literals
...
#KT-7273 Fixed
2015-06-03 14:42:57 +03:00
Denis Zharkov
70dbbd8fda
Resolve constructors declared in traits and objects
...
It prevents exceptions and produces less red code
#EA-68667 Fixed
2015-06-02 14:07:49 +03:00
Mikhail Glukhikh
969993bd09
Fix for EA-68871 #EA-68871 Fixed
2015-06-02 10:56:13 +03:00
Alexander Udalov
596d378962
Fix abstract method error: implement arity in function references
2015-06-01 19:23:09 +03:00
Alexander Udalov
28addcf8e7
Do not generate annotations of method parameters on its $default synthetic method
...
#KT-7892 Fixed
2015-06-01 19:23:08 +03:00
Alexander Udalov
4f77b44ac3
Minor, move constant to the proper place
2015-06-01 19:23:08 +03:00
Alexander Udalov
df4d5a3ae2
Fix initialization order of enum entries and companion
...
#KT-5761 Fixed
2015-06-01 19:23:08 +03:00
Evgeny Gerashchenko
88e8988b18
Stabilized order of bytecode for when mappings initialization.
2015-06-01 19:02:13 +03:00
Evgeny Gerashchenko
7de531fe09
Fixed package proto for circular dependencies. Case when package is present in different modules which depend on each other. We should generate separate package facades for this case.
2015-06-01 19:02:11 +03:00
Valentin Kipyatkov
8fd6a64be9
Refactored methods for val/var in PSI
2015-06-01 18:23:34 +03:00
Valentin Kipyatkov
eef0e8e447
JetBlockExpression.getStatements() returns List<JetExpression> instead of List<JetElement>
2015-05-29 14:22:56 +03:00
Zalim Bashorov
68f851cbdc
Move JvmCodegenUtil#getDelegationConstructorCall to common place (BindingContextUtils)
2015-05-28 10:30:54 +03:00
Michael Bogdanov
e20a5121c7
Support private package properties in inline functions
2015-05-27 18:09:40 +03:00
Dmitry Jemerov
1188e57597
rename @overloads annotation to @jvmOverloads
2015-05-27 12:23:08 +02:00
Alexander Udalov
48b18f18d3
Restore explicit imports of Kotlin function types in Java
...
This is a follow-up to 738a84e259 and
d4965a4f3e . Optimize imports in all files
affected in those commits, drop temporary _.kt
2015-05-26 18:46:27 +03:00
Mikhail Glukhikh
4570872bfd
Postfix expression code generation fixed as per KT-7561.
...
A set of tests for KT-7561 on codegen side, including exotic inc() functions().
#KT-7561 Fixed.
2015-05-26 15:20:37 +03:00
Alexander Udalov
9ba6d91e2e
Prepare JVM runtime for support of reflection on functions
...
Introduce abstract class FunctionReference, which is supposed to be a
superclass for all anonymous classes generated for function references. Each
anonymous subclass will have statically-generated symbol info, which will be
used by reflection to locate the symbol
2015-05-26 15:05:01 +03:00
Alexander Udalov
9aeae7ddc6
Extract FunctionReferenceGenerationStrategy to top level
2015-05-26 15:05:00 +03:00
Alexander Udalov
49004a8b8e
Conform functions to extension functions and vice versa
...
#KT-5989 Fixed
2015-05-26 15:04:56 +03:00
Alexander Udalov
4141e0a8df
Introduce fictitious numbered Function class descriptors
2015-05-26 15:04:54 +03:00
Alexander Udalov
27ed098467
Introduce kotlin.jvm.internal.Lambda, superclass for all lambdas
...
It has its arity precomputed, as opposed to the future KFunctionImpl inheriting
from FunctionImpl, for which the computation of arity can take some time and so
it shouldn't be passed in the constructor and saved as a field
2015-05-26 15:04:54 +03:00
Alexander Udalov
86ecb423f6
Drop generic parameters from FunctionImpl classes in JVM runtime
...
They are not used in any way but cause some complex code in JVM back-end
2015-05-26 15:04:53 +03:00