Commit Graph

11268 Commits

Author SHA1 Message Date
Mikhail Glukhikh 3ad06f169d Solution for EA-66870: Foo<in *> and Foo<out *> types are now treated as incorrect.
#EA-66870  Fixed.
2015-05-27 19:07:46 +03:00
Mikhail Glukhikh 9b50705a0e Warning fixed 2015-05-27 19:07:43 +03:00
Mikhail Glukhikh 4fb331ecd3 Solution for KT-7838: now data flow information at the end of when expression is determined correctly.
#KT-7838  Fixed.
2015-05-27 19:07:41 +03:00
Alexey Sedunov 9e69b74a15 Extract Function: Extract smart-cast value as parameter
#KT-7576 Fixed
2015-05-27 18:41:42 +03:00
Michael Bogdanov e20a5121c7 Support private package properties in inline functions 2015-05-27 18:09:40 +03:00
Denis Zharkov 53e9234ea9 Add quickfix for replacing positioned arguments in Java annotation 2015-05-27 17:41:27 +03:00
Valentin Kipyatkov d3403dee1a DeprecatedSymbolUsageFix preserves comments 2015-05-27 16:15:54 +03:00
Valentin Kipyatkov 8b44c93667 JetPsiFactory.createByPattern supports PsiChildRange as argument, used it in ConvertToForEachFunctionCallIntention 2015-05-27 16:15:54 +03:00
Valentin Kipyatkov b957584d91 Refactored JetPsiFactory.createByPattern to handle different argument types uniformly 2015-05-27 16:15:54 +03:00
Valentin Kipyatkov 2eaf767521 JetPsiFactory: create by pattern allows Name's as arguments + changed placeholder text specification format 2015-05-27 16:15:53 +03:00
Valentin Kipyatkov c167ddb2fe Minor 2015-05-27 16:15:53 +03:00
Valentin Kipyatkov df0d27b8b2 Split if intention preserves comments 2015-05-27 16:15:53 +03:00
Valentin Kipyatkov b39e9ebdb2 Implemented special CommentSaver helper for not loosing comments when doing code transformation 2015-05-27 16:15:53 +03:00
Valentin Kipyatkov 333445d93e Fixed Convert to foreach intention loosing comments 2015-05-27 16:15:52 +03:00
Valentin Kipyatkov 0fe334fd55 KT-7702 Split into 2 if's intention: produce better result for return
#KT-7702 Fixed
2015-05-27 16:15:52 +03:00
Valentin Kipyatkov 04bee4dd7d Fixing issues after code review 2015-05-27 16:15:51 +03:00
Valentin Kipyatkov 17f0ac9ba7 Don't use plain text generation 2015-05-27 16:15:51 +03:00
Valentin Kipyatkov 281acb860e Loading of annotation class arguments from compiled classes 2015-05-27 16:15:50 +03:00
Valentin Kipyatkov 0c397548e8 createByPattern fix (after we changed way how JetPsiFactory.createArgument works 2015-05-27 16:15:49 +03:00
Valentin Kipyatkov 6b66e3b0e6 JetPsiFactory: refactored method for creating argument + introduced ability to create arbitrary constructs by pattern 2015-05-27 16:15:49 +03:00
Valentin Kipyatkov 97d3620262 DeprecatedSymbolUsageFix: dealing with vararg's 2015-05-27 16:15:48 +03:00
Valentin Kipyatkov f58ce760ca DeprecatedSymbolUsageFix: support for optional parameters (not complete) 2015-05-27 16:15:47 +03:00
Valentin Kipyatkov 33caa7ad36 Moved utility method 2015-05-27 16:15:46 +03:00
Valentin Kipyatkov a6f76bbf76 Fixed keywords after 'this@' completion + fixed implementation of JetExpressionWithLabel.getLabelName() 2015-05-27 16:15:46 +03:00
Valentin Kipyatkov df850d7035 DeprecatedSymbolUsageFix: initial implementation 2015-05-27 16:15:45 +03:00
Valentin Kipyatkov d7c64d44b6 Better implementation of "Move lambda outside parenthesis" 2015-05-27 16:15:44 +03:00
Valentin Kipyatkov 25e323e960 Methods for editing in JetValueArgumentList 2015-05-27 16:15:44 +03:00
Valentin Kipyatkov 5a737b8973 Correctness check in JetPsiFactory.createExpression 2015-05-27 16:15:44 +03:00
Dmitry Jemerov 1188e57597 rename @overloads annotation to @jvmOverloads 2015-05-27 12:23:08 +02:00
Natalia Ukhorskaya 2d509b3211 Write correct lineNumbers for properties with comments 2015-05-27 11:17:46 +03:00
Denis Zharkov eb80764d21 Introduce forceResolveLazyTypes into TypeResolutionContext
The main reason is to force type resolution when resolving
type arguments in class literal as annotation value argument:

@Ann(Array<String>::class) class Ann

`String` left unresolved unless this commit is applied.

Note, that currently forced calculations used only when bare types are allowed
as it's true for class literals resolution and currenlty it's enough.
2015-05-27 08:24:42 +03:00
Alexander Udalov f9556e584d Minor, suppress code conformance test for generated sources 2015-05-27 01:44:19 +03:00
Alexander Udalov 6ae7ed1cc4 Add some new tests on functions and extension functions 2015-05-27 01:44:19 +03:00
Ilya Gorbunov 84ca26719d Deprecate meaningless or vague-defined operations with Char operands.
Change expected test output.
2015-05-27 00:58:35 +03:00
Alexey Sedunov c757701a87 Refactoring: Extract function getContainingPseudocode() 2015-05-26 19:29:05 +03:00
Alexey Sedunov b6ea2d4fd4 Control-Flow: Compute type predicates for arguments of unresolved calls 2015-05-26 19:29:04 +03:00
Alexey Sedunov 036e2c585b Refactoring: Introduce getReferenceTargets() function 2015-05-26 19:28:11 +03:00
Alexey Sedunov 640f07969a Refactoring: Extract createUnresolvedCall() functions 2015-05-26 19:28:10 +03:00
Alexey Sedunov 3d3b5591e1 Control-Flow: Improve debug text of ReadValueInstruction 2015-05-26 19:28:09 +03:00
Alexey Sedunov 868329e3cb Control-Flow: Fix pseudocode generation for combined get/set and invoke conventions
#KT-4462 Fixed
 #KT-4681 Fixed
2015-05-26 19:28:07 +03: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
Mikhail Glukhikh 5723c2a077 Front-end fix: result type corrected for increment / decrement expressions. Smart cast allowed on a postfix increment result. See KT-7561.
Now result type is receiver type for postfix increment, or increment result type for prefix increment.
A set of relevant tests.
2015-05-26 15:20:25 +03:00
Alexander Udalov ea6d0b464d Report error when free function is called as extension 2015-05-26 15:05:04 +03:00
Svetlana Isakova 14c2690447 Distinguish between no declared arguments and an empty argument list
in a function literal
If there are no arguments, any number of them might be expected
2015-05-26 15:05:03 +03:00
Svetlana Isakova d9568ef88c Added special type constructor for function/ extension function
that stores an information about declared argument types
2015-05-26 15:05:02 +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 4d00077ffb Delete assertion on receiver presence in 'invoke'
#KT-6541 Fixed
 #KT-7383 Fixed
2015-05-26 15:04:59 +03:00
Alexander Udalov 34c6af0039 Advance stub and JVM ABI versions due to function type reform 2015-05-26 15:04:58 +03:00