Pavel V. Talanov
9599f7d98c
Test for delegated members being overridden
2013-09-30 20:54:42 +04:00
Pavel V. Talanov
51a6bcb727
Test for reporting clashes with multiple delegated methods
...
Verifies that the order in which traits are inherited is irrelevant
2013-09-30 20:54:41 +04:00
Mohammad Shamsi
f554ff3c8c
KT-3945 Fixed - Prohibit modifiers for packages
2013-09-26 15:25:36 +04:00
Andrey Breslav
8f6b6639c5
Allow no else in annotated when-statements
2013-09-24 06:58:42 -07:00
Andrey Breslav
db9dd5d320
Allow annotations on loop statements
2013-09-24 06:58:41 -07:00
Andrey Breslav
c7c151a726
Support suppression on expressions
2013-09-24 06:58:41 -07:00
Andrey Breslav
b379ab3ebd
Resolve annotations on expressions and multi-declarations
2013-09-24 06:58:41 -07:00
Andrey Breslav
2dfaa81995
Tests for 'suppress' annotation
2013-09-24 06:58:40 -07:00
Svetlana Isakova
b9f55f5070
test added
2013-09-17 16:09:27 +04:00
Svetlana Isakova
845b6f7d7e
fixed bug
...
NULL_FOR_NONNULL_TYPE can represent type mismatch error as well
(later the whole method 'makeTraceInterceptingTypeMismatch' should be removed)
2013-09-17 16:09:26 +04:00
Andrey Breslav
a9134f8eff
Do not allow inference of type arguments on the rhs if there's no information available
2013-09-13 22:41:06 +02:00
Andrey Breslav
5c86a5bd7c
Allow bare types on the right-hand side of as/as?/is/!is
2013-09-13 22:41:06 +02:00
Andrey Breslav
69cc11d035
Existing tests updated according to "'Else' is not required in 'when' if Unit is expected"
2013-09-13 22:05:37 +02:00
Andrey Breslav
c017858f77
'Else' is not required in 'when' if Unit is expected
2013-09-13 22:04:46 +02:00
Svetlana Isakova
298d344c31
check constants with Unit return type as usual
2013-09-13 16:04:17 +04:00
Svetlana Isakova
b6386e345c
added positioning for 'ILLEGAL_ESCAPE' error
2013-09-13 16:04:17 +04:00
Svetlana Isakova
96db2ecabd
added different errors instead of ERROR_COMPILE_TIME_VALUE with different text
...
check type for constants in DataFlowUtils
2013-09-13 16:04:17 +04:00
Svetlana Isakova
5f189a8c0f
KT-3833 Invoke method not working inside class object?
...
#KT-3833 Fixed
2013-09-13 16:04:17 +04:00
Evgeny Gerashchenko
e4d8e4d61b
Not ignoring other properties in scope.
...
First one (almost randomly) was chosen instead of ambiguity.
2013-09-12 14:58:58 +04:00
Nikolay Krasko
e4c1fe7c3a
Report unsupported annotations for local variables
2013-09-11 12:01:34 +04:00
Nikolay Krasko
08b8f56740
Fix rewrite for ANNOTATION slice (EA-49336)
2013-09-11 12:01:32 +04:00
Andrey Breslav
fca6182288
Fixed the case of "Any is/as List<*>" for erased cast diagnostic
2013-09-06 13:37:09 +04:00
Andrey Breslav
e3175c66e8
Fixing failed tests: do not report anything on casts that can never succeed
2013-09-05 15:03:37 +04:00
Andrey Breslav
e3079ac667
Erased casts supported
2013-09-05 14:17:33 +04:00
Andrey Breslav
a28d211442
'Cast can never succeed' diagnostics improved
2013-09-05 14:17:32 +04:00
Svetlana Isakova
a53eae79b5
bug fixed: analyze arguments in FREE expression position
2013-09-03 19:56:20 +04:00
Svetlana Isakova
b5e6568726
bug fixed: do not substitute type parameters twice
...
through final argument check
2013-09-03 19:50:00 +04:00
Svetlana Isakova
7fabfd8771
test data fixed
...
temporary
when ambiguity inner calls are not completed
2013-09-03 13:09:18 +04:00
Svetlana Isakova
79c18f1c56
test data fixed
...
temporary
2013-09-03 13:09:17 +04:00
Svetlana Isakova
efda014109
test data fixed
...
ignore error types in resolving constraints for generic functions
'if' is resolved as special function
2013-09-03 13:09:17 +04:00
Svetlana Isakova
335e0d7d1b
test data fixed
...
can't implicitly convert to Unit any more in 'if'
as 'if' is resolved as special function call 'fun IF<T>(T, T)'
2013-09-03 13:09:17 +04:00
Svetlana Isakova
c739632c57
report 'ambiguity' on reference, not on the whole expression
...
as other type inference errors
2013-09-03 13:09:15 +04:00
Svetlana Isakova
0084b68176
analyze incomplete 'in' expression
2013-09-03 13:09:14 +04:00
Svetlana Isakova
a493125a75
refactoring: fixes after review
...
rename, removed unnecessary methods, improved test
2013-09-03 13:09:11 +04:00
Svetlana Isakova
928133b69b
small fixes after review
2013-09-03 13:09:10 +04:00
Svetlana Isakova
fd5a2056c1
analyze labeled function literals as usual ones
...
(specially as function literals, not as other expressions)
2013-09-03 13:09:10 +04:00
Svetlana Isakova
8f29968183
test data updated
...
arguments analyzed even if there's type inference error
2013-09-03 13:09:09 +04:00
Svetlana Isakova
30b0a72c6b
analyze all arguments with unknown expected type
...
in the beginning of call resolution process
2013-09-03 13:09:07 +04:00
Svetlana Isakova
756cb3759b
fixed: use function placeholder when there is no declared value parameter list
...
(not when there is no value parameters)
2013-09-03 13:09:06 +04:00
Svetlana Isakova
dc51a2d238
analyze a lot of expressions in independent of context (expected type) mode
2013-09-03 13:09:05 +04:00
Svetlana Isakova
6429239f3f
rewrote analyzing expression with type rhs
...
removed unnecessary temporary trace (and so extra 'getType' for left expression)
2013-09-03 13:09:03 +04:00
Svetlana Isakova
7b04755a59
through completion phase result type of call should be updated
...
with respect to being selector in safe call expression
2013-09-03 13:09:02 +04:00
Svetlana Isakova
4621fe6dfa
resolve elvis operator as call
2013-09-03 13:09:02 +04:00
Svetlana Isakova
aba70e047d
resolve a!! as call
2013-09-02 23:18:46 +04:00
Svetlana Isakova
46cb6b3242
complete resolve for array access expression
2013-09-02 23:18:45 +04:00
Svetlana Isakova
e2f681c587
report type mismatch deeply on branches for if
...
in type argument inference case
2013-09-02 23:18:45 +04:00
Svetlana Isakova
99bb6f13b5
data flow info for arg may affect next argument's type for type argument inference case
2013-09-02 23:18:45 +04:00
Svetlana Isakova
27cff93ed8
use data flow info in constraint system
...
intersect data flow value possible types
add intersection type (or exact type for the most cases) as a lower bound to constraint system
always get common super type for intersection type as a result
(avoid returning it, even in error messages)
2013-09-02 23:18:45 +04:00
Svetlana Isakova
0609f61ee7
added test for nontrivial nested calls
2013-09-02 23:18:44 +04:00
Svetlana Isakova
0849798af0
report only 'The value is out of range'
...
not 'An integer literal does not conform to the expected type Int/Long'
2013-09-02 23:18:44 +04:00