Stanislav Erokhin
1d9ca06b96
Remake KotlinTypes.
2016-06-09 12:57:59 +03:00
Stanislav Erokhin
56122460aa
Remove type capabilities.
2016-06-09 12:57:58 +03:00
Stanislav Erokhin
4c0572fb2f
Remove type capability CustomTypeVariable.
2016-06-09 12:57:56 +03:00
Stanislav Erokhin
a5c1e009c3
Remove type capability AbbreviatedType.
2016-06-09 12:57:55 +03:00
Stanislav Erokhin
203c4cd94d
Remake Raw type representation.
...
(cherry picked from commit b21cede)
2016-06-09 12:57:53 +03:00
Stanislav Erokhin
04e97f5058
Refactoring. Do not use SubtypingRepresentatives as TypeCapability.
2016-06-09 12:57:51 +03:00
Stanislav Erokhin
1eaefa7fed
Refactoring. Remove type capability Flexibility.
2016-06-09 12:57:50 +03:00
Stanislav Erokhin
669558c4ba
Refactoring. Move flexible type factory to deserialization module.
2016-06-09 12:57:48 +03:00
Stanislav Erokhin
42857992ed
Minor. Add ALLOW_AST_ACCESS to two tests.
...
We suppose, that AST access is allowed if we have property with initializer.
2016-06-09 12:57:47 +03:00
Stanislav Erokhin
7bc2c55d12
Refactoring. Create WrappedType.
2016-06-09 12:57:46 +03:00
Stanislav Erokhin
957bae18be
Refactoring. Move flexible type creation to KotlinTypeFactory.
2016-06-09 12:57:44 +03:00
Stanislav Erokhin
3a451744c5
Introduce KotlinTypeFactory
2016-06-09 12:57:43 +03:00
Stanislav Erokhin
8c6dd95e3f
Introduce SimpleType.
2016-06-09 12:57:41 +03:00
Dmitry Petrov
44829a61e7
Report redeclaration errors for type aliases vs class/interface/object.
2016-06-09 10:27:51 +03:00
Dmitry Petrov
d3721872b2
Tests for type alias diagnostics: type parameter bound violation in type alias constructor
2016-06-09 10:27:51 +03:00
Dmitry Petrov
b552425558
Tests for type alias diagnostics: type projections in type alias constructor
...
(should report same errors as for classes)
2016-06-09 10:27:51 +03:00
Dmitry Petrov
d86be43171
Tests for type alias diagnostics: wrong number of type arguments in type alias constructor
2016-06-09 10:27:51 +03:00
Dmitry Petrov
ccbade663b
Do not perform type alias expansion for error types.
2016-06-09 10:27:50 +03:00
Dmitry Petrov
b2e5cfebee
Diagnostics for type alias expansion errors in type alias RHS
2016-06-09 10:27:50 +03:00
Ilya Gorbunov
753be08de6
Minor: update links in ReadMe
2016-06-08 21:45:25 +03:00
gandrianakis
83e97d272e
Small grammar fixes for documentation of default value handling related methods for Map
2016-06-08 21:45:24 +03:00
gandrianakis
cbc5c6f792
Slight improvement of wording in the section that explains the benefits of contributing code examples for library functions
2016-06-08 21:34:18 +03:00
Pavel V. Talanov
e032e4ad54
Update changelog for 1.0.3
2016-06-08 19:29:21 +03:00
Pavel V. Talanov
b08881df58
Changelog, minor: merge duplicating JS sections
2016-06-08 19:29:07 +03:00
Denis Zharkov
9c929dd609
Minor. Rename MandatoryMethodTransformer -> FixStackWithLabelNormalizationMethodTransformer
...
It's necessary because some usages suppose that it's only purpose is fixing stack
2016-06-08 18:53:16 +03:00
Denis Zharkov
2c78ce22a5
Minor. Simplify coroutine transformation
2016-06-08 18:53:16 +03:00
Denis Zharkov
771cca9c23
Fix some try-catch block related problems in coroutine transformer
...
Split all try-catch blocks when they intersect suspension points
2016-06-08 18:53:16 +03:00
Denis Zharkov
e802049fd0
Ignore handleReturn calls if functions is not operator
2016-06-08 18:53:16 +03:00
Denis Zharkov
692acc463a
Fix handleResult call generation for statement-like last expression in a block
2016-06-08 18:53:16 +03:00
Denis Zharkov
3a5197d1ae
Minor. Simplify collecting save/restore markers for FixStackMethodTransformer
2016-06-08 18:53:16 +03:00
Denis Zharkov
0d01edb7f9
Adapt FixStackAnalyzer to code generated by coroutine transformation
...
Without this change internal error happens while inlining coroutine code with try/catch inside
Also get rid of hack with SKIP_MANDATORY_TRANSFORMATIONS_ANNOTATION_DESC
See comment within MethodAnalyzer for clarification
2016-06-08 18:53:16 +03:00
Denis Zharkov
678e8c2baa
Setup label value in constructor to be invalid until 'invoke(Controller)' call
2016-06-08 18:53:16 +03:00
Denis Zharkov
759cb83dfb
Add checks that coroutines are available at the given language level
2016-06-08 18:53:16 +03:00
Denis Zharkov
2bdaec6eac
Refine definition of whether call is suspension point
...
It's not about all calls to suspend functions, they may called from non-coroutine code
2016-06-08 18:53:16 +03:00
Denis Zharkov
1067531224
Introduce light-weight user data parts into FunctionDescriptor
2016-06-08 18:53:16 +03:00
Denis Zharkov
dd3de8372f
Minor. Cleanup FunctionDescriptorImpl
2016-06-08 18:53:16 +03:00
Denis Zharkov
07592398c1
Preserve sources properly for coroutine parts
...
Otherwise incremental reporting leads to exception when inlining into coroutine body happens
2016-06-08 18:53:16 +03:00
Denis Zharkov
7dda2d9f62
Add ability to set up source element when copying descriptor
2016-06-08 18:53:16 +03:00
Denis Zharkov
dddd7413a1
Fix generated code for suspending in the middle of object construction
2016-06-08 18:53:16 +03:00
Denis Zharkov
b8d4d39f4d
Add custom applicability checks for suspend/coroutine modifiers
2016-06-08 18:53:16 +03:00
Denis Zharkov
d760a2ec3b
Add CallChecker prohibiting non-local suspension calls
...
Effectively suspension point is local <=> return to relevant lambda is allowed in place
2016-06-08 18:53:16 +03:00
Denis Zharkov
b1189eff23
Make suspension calls generation more stable
...
Instead of performing signature change during transformation
it's convinient to make just when generating corresponding call,
for example there is no need to think about default parameters as they just work as is
See comment above replaceSuspensionFunctionViewWithRealDescriptor for clarification
2016-06-08 18:53:16 +03:00
Denis Zharkov
84ae28992e
Minor. Drop unused class
2016-06-08 18:53:16 +03:00
Denis Zharkov
611490e080
Support non-local returns to coroutine label from inline lambda
...
- Use proper class descriptor when retreiving continuation object (see previous commit)
- Use return type as VOID for such cases
- Load correct labels related to coroutine lambda from outer context
2016-06-08 18:53:16 +03:00
Denis Zharkov
94bd6dcc82
Use proper coroutine class descriptor for extension receiver generation
...
Before this commit context.getThisDescriptor() has been used, that was quite correct
until suspension happens inside inlined lambda (it has different this-descriptor)
2016-06-08 18:53:16 +03:00
Denis Zharkov
75e112e752
Implement basic support for coroutines in JVM backend
2016-06-08 18:53:16 +03:00
Denis Zharkov
077fc528d1
Minor. Change CompilationException parameter to @Nullable
...
A lot of call sites actally pass null as an element,
so it's better to fail with original stack-trace instead of NPE
caused by nullability check
2016-06-08 18:53:16 +03:00
Denis Zharkov
20d1d12f3b
Revert "'yield' reserved as a keyword"
...
This reverts commit 434082cadb .
2016-06-08 18:53:16 +03:00
Denis Zharkov
5c1e17c8e7
Revert "Completion fix for reserved 'async' syntax"
...
This reverts commit 318f0c89b2 .
2016-06-08 18:53:16 +03:00
Denis Zharkov
3ede8f97e6
Revert "Quick fix for deprecated async syntax"
...
This reverts commit afc1e24571 .
2016-06-08 18:53:16 +03:00