Commit Graph

585 Commits

Author SHA1 Message Date
Svetlana Isakova ca88a01e1d no 'dangling function literal' check for nested calls 2013-06-06 17:20:10 +04:00
Svetlana Isakova f41584c7ab tests added
for inference for delegated properties
2013-06-06 16:31:06 +04:00
Svetlana Isakova 7e564de71a added constraint for package level delegated property 2013-06-04 22:11:43 +04:00
Svetlana Isakova 2337f4b948 bug fix
do not combine receiverInfo with error selectorInfo
2013-06-04 22:11:43 +04:00
Svetlana Isakova ecec6acde8 use explicit type of delegated property as expected
while resolving constraint system for delegated expression
2013-06-04 22:11:43 +04:00
Svetlana Isakova f05f616230 KT-2422 Invalid warning "Condition is always true"
#KT-2422 fixed
2013-05-31 16:29:07 +04:00
Natalia.Ukhorskaya b9e5227b58 Change String argument of property delegate method to PropertyMetadata 2013-04-30 21:47:24 +04:00
Natalia.Ukhorskaya a9b4a342e7 Add diagnostics for get/set methods of property delegate 2013-04-30 20:08:06 +04:00
Natalia.Ukhorskaya c58d4fd6d2 Resolve expression in property delegate 2013-04-30 20:08:04 +04:00
Natalia.Ukhorskaya e7bf3b141f Modify analysis for property initializer. Add errors about delegated property accessors. 2013-04-30 20:07:55 +04:00
Wojciech Lopata 59716fec9c Cleanup in a test 2013-04-26 13:12:20 +04:00
Mikhael Bogdanov aa2db75266 KT-3389: Local class construction results in CompilationException && KT-2873 && KT-3210
KT-2873: VerifyError on instantiating a local class inside a closure
KT-3210 Inline Class: CompilationException: Back-end (JVM) Internal error: wrong code generated java.lang.ArrayIndexOutOfBoundsException null

 #KT-3389 Fixed
2013-04-24 13:49:47 +04:00
Alexander Udalov fee7846c7e LHS of callable reference can't be a type parameter 2013-04-22 17:59:31 +04:00
Alexander Udalov d40906a690 Disallow references to extensions in classes
It's not clear in which order should the two receiver arguments be passed to
them, and there's no corresponding K*FunctionN class for now

 #KT-1183 In Progress
2013-04-22 17:59:31 +04:00
Alexander Udalov c4b4fa750c Resolve callable reference expressions
#KT-1183 In Progress
2013-04-22 17:59:31 +04:00
Alexander Udalov 6f6cb03549 Make FunctionN interfaces
FunctionN and ExtensionFunctionN are now interfaces, with the corresponding
implementations in FunctionImplN and ExtensionFunctionImplN

Update test data
2013-04-22 17:59:29 +04:00
Nikolay Krasko 5df85f6100 KT-3525 Duplicate inner class name not detected
#KT-3525 Fixed
2013-04-19 01:10:54 +04:00
Andrey Breslav fe4dd2f661 Fix tests (by extracting a method and calling it multiple times) 2013-04-18 17:36:30 +04:00
Andrey Breslav 140382e280 PSI getter fixed: left-hand side of a binary expression can now be null
EA-35976 - IAE: FqNameUnsafe.validateFqName
2013-04-18 16:34:10 +04:00
Zalim Bashorov a4c02da10d Merge pull request #244 from lopekpl/type_mismatch3
QuickFix for EXPECTED_PARAMETER/RETURN_TYPE_MISMATCH
2013-04-17 07:35:08 -07:00
Mikhael Bogdanov 57b161b08a KT-3500: ClassFormatError: Duplicate method name&signature in class file && KT-3429: Traits override bug 2013-04-17 15:23:33 +04:00
Wojciech Lopata 328e579852 Fix reporting of EXPECTING_PARAMETER/RETURN_TYPE_MISMATCH 2013-04-16 14:06:09 +02:00
Andrey Breslav 8a79e7ab7d .jet -> .kt 2013-04-12 21:06:54 +04:00
Svetlana Isakova 7588c8d81f mark 'unresolved' if invoke method on type parameter
instead of resolve to error element
2013-04-12 20:01:09 +04:00
Svetlana Isakova 204ffde78a added errors TYPE_PARAMETER_ON_LHS_OF_DOT,
TYPE_PARAMETER_IS_NOT_AN_EXPRESSION
fixed exception from ea
2013-04-12 17:35:00 +04:00
Svetlana Isakova 3168b732d3 annotate 'getArrayExpression' with @Nullable @IfNotParsed
from EA
2013-04-12 17:34:59 +04:00
Nikolay Krasko ebd72df058 KT-3491 Wrong (or not obvious) warning
#KT-3491 Fixed
2013-04-10 13:14:49 +04:00
Svetlana Isakova d843608298 'checkType' for qualified properties as function arguments 2013-04-03 20:44:47 +04:00
Svetlana Isakova 8f1b728a08 try to use bounds in type inference
if some parameters are unknown
2013-04-03 15:51:17 +04:00
Svetlana Isakova 12c0a2cb77 KT-3461 Nullable argument allowed where shouldn't be
#KT-3461 Fixed
2013-04-01 19:07:36 +04:00
Evgeny Gerashchenko 0fee69fe07 Prioritized synthetic and not synthetic functions. 2013-03-28 20:07:47 +04:00
Evgeny Gerashchenko c619685dc8 Added test with overridden j.l.Object methods in trait. 2013-03-28 15:54:51 +04:00
Evgeny Gerashchenko 5ccbce6de6 Got rid of "tuple" word all over the code. 2013-03-22 16:38:25 +04:00
Andrey Breslav 3bd202de84 Allow to call += on a val 2013-03-21 21:21:54 +04:00
Mikhael Bogdanov 79bf174e93 Warning for unused function literal in do..while 2013-03-20 20:50:06 +04:00
Svetlana Isakova df230d36c2 complete nested calls for array set expression correctly 2013-03-20 17:27:45 +04:00
Svetlana Isakova 1b1ee18f97 KT-3395 mapOf function can't be used as literal
#KT-3395 Fixed
2013-03-19 16:47:22 +04:00
Evgeny Gerashchenko 735f06e78f Added test for KT-334 Can't use java.lang.Comparable by the short name
#KT-334 obsolete
2013-03-14 20:49:41 +04:00
Evgeny Gerashchenko fd2d5975e4 Fixed useless hidden import & useless simple import diagnostics when Java class is resolved as both class and namespace. 2013-03-12 20:40:18 +04:00
Svetlana Isakova 7b6dfc3470 small fix while choosing maximally specific
return success if there is one candidate after filterOverrides step
 #KT-1461 fixed
2013-03-11 14:54:16 +04:00
Peter Tseng cd56678467 Change ANONYMOUS_INITIALIZER from _WITHOUT_CONSTRUCTOR to _IN_TRAIT
"since we made all classes have constructors some time ago", this error
doesn't even trigger on a class such as:
class testClass { {} }
It does trigger on a trait:
trait testTrait { {} }

Therefore, the error message should be changed to reflect the new
behavior.
However, an actual quickfix for this will be more involved. It is not a
good idea to simply delete the initializer, since it could contain
valuable code that the user wants to keep.
2013-03-08 02:11:58 -05:00
Svetlana Isakova d7412ecd9f fixed test data
type mismatch with nothing (after change in ConstraintSystemImpl)
render 'CANT_INFER' type as '???'
2013-03-07 13:11:21 +04:00
Svetlana Isakova 1d55e359a5 complete type inference(*) for variable as function call as well
* dependent on expected type
+ get rid of instanceof ResolvedCallImpl check
2013-03-07 13:11:21 +04:00
Svetlana Isakova 0530df6f7b use TypeCheckingProcedure for generating constraints
(in ConstraintSystemImpl)
2013-03-07 13:11:21 +04:00
Wojciech Lopata 75528e0a4a KT-3378 "Type mismatch on override" not present when the initializer is syntactically incorrect
#KT-3378 Fixed
2013-03-06 15:18:37 +04:00
Wojciech Lopata bc59ed75ca KT-1019 parser should recover from missing parentheses in function declaration
#KT-1019 Fixed
2013-02-28 12:00:33 +01:00
Svetlana Isakova 8ef067be77 KT-3344 InternalError in compiler when type arguments are not specified
#KT-3344 fixed
2013-02-25 18:19:52 +04:00
Wojciech Lopata 23ce144f9d SUPERTYPE_NOT_INITIALIZED_DEFAULT error removed
It was merged with SUPERTYPE_NOT_INITIALIZED.
2013-02-21 17:50:52 +01:00
Mikhael Bogdanov 029b2d9770 Test fixes for 'New diagnostic error for ambiguous object expression type' 2013-02-19 17:56:56 +04:00
Mikhael Bogdanov 1662c5cb75 New diagnostic error for ambiguous object expression type 2013-02-19 17:56:55 +04:00