Commit Graph

191 Commits

Author SHA1 Message Date
Yan Zhulanow 16b94feea6 Minor: Remove an obsolete TODO comment 2019-02-25 14:43:55 +03:00
Yan Zhulanow 6cd980765c Do not issue exceptions for non-captured local variables
This partly fixes KT-28192.
2019-02-25 14:43:55 +03:00
Yan Zhulanow 4ae01badff Extract function: avoid same parameter names 2019-02-25 14:43:55 +03:00
Yan Zhulanow 7de5ddaac9 Fix receiver evaluation for primitive receiver types 2019-02-25 14:43:55 +03:00
Yan Zhulanow cf9461847b Hide unrelated this entries in Kotlin Watches mode 2019-02-25 14:43:54 +03:00
Yan Zhulanow f5a3a46e76 Watches: Hide 'this' if it's a continuation 2019-02-25 14:43:54 +03:00
Yan Zhulanow 227a7e5609 Provide access to 'coroutineContext' inside suspend functions/lambdas (KT-24829) 2019-02-25 14:43:54 +03:00
Yan Zhulanow cf925fc2ad Activate Kotlin stack frame even if there is no Kotlin strata 2019-02-25 14:43:54 +03:00
Yan Zhulanow 4c681c787d Watches: Add Kotlin/JVM views to watches window (KT-28134, KT-28087, KT-22250)
Kotlin mode: show only Kotlin variables and captured values. The variable names are Kotlin-friendly.
JVM mode: show all variables available in the current stack position, including synthetic ones.
2019-02-25 14:43:53 +03:00
Yan Zhulanow 5c419fc629 Evaluator: New implementation for variable finder
Support both old and new receiver variable conventions in variable finder.
2019-02-25 14:43:53 +03:00
Yan Zhulanow ea462091c4 Support new convention for local variables name mangling: '$receiver' -> '$this$<label>' (KT-26913) 2019-02-25 14:43:53 +03:00
Ilmir Usmanov 1777849ff3 Generate correct linenumber for the debugger to see the return value
of suspend function.

 #KT-20322 Fixed
2019-02-22 17:37:32 +03:00
Yan Zhulanow ef08110354 Evaluator: Render inline class values using its toString() implementation (KT-27414) 2018-12-12 21:40:46 +09:00
Yan Zhulanow 4b4d8dd660 Fix breakpoints for the same inline function nested calls (KT-22366)
This commit changes the format of the synthetic local variables for inline functions.
2018-12-12 21:40:44 +09:00
Yan Zhulanow e12af0e2d1 Fix evaluation for captured inline classes (KT-28487) 2018-12-12 21:40:44 +09:00
Yan Zhulanow 27ea02929a Fix evaluation for static interface methods declared in Java (KT-23585) 2018-12-12 21:40:43 +09:00
Yan Zhulanow c88d8a5e0d Evaluate: Support synthetic 'field' variable evaluation (KT-28342) 2018-12-12 21:40:43 +09:00
Yan Zhulanow ada71ce3cd Evaluate: Use '<name>_field' syntax for field value evaluation (KT-14075) 2018-12-12 21:40:42 +09:00
Yan Zhulanow 713dc589e0 Debugger: Allow to evaluate private properties from companion objects (KT-26795) 2018-10-24 20:12:24 +03:00
Stanislav Erokhin 4ca0c60066 Temporary specify type explicitly for sequence method in debugger tests. 2018-09-19 15:46:24 +03:00
Ilya Gorbunov 1b889c976a Use new sequence builders in tests
Coroutine tests will fail when LV=1.2 because there're no such builders
in kotlin.coroutines.experimental.

#KT-26678
2018-09-16 23:30:36 +03:00
Yan Zhulanow 64e85e8a0c Support new $this_<label> field naming convention in debugger 2018-09-11 16:41:21 +03:00
Alexey Tsvetkov 49bddcd220 Use release coroutines in evaluate tests 2018-08-30 14:57:12 +03:00
Ilmir Usmanov 300876348a Fix line numbers generation for coerced primitives
in coroutines
 #KT-25076: Fixed
2018-08-15 13:47:45 +03:00
Yan Zhulanow a2fdf7d47d Evaluator: Support when expressions (EA-119639) 2018-07-12 20:36:41 +03:00
Yan Zhulanow 115356b990 Eval4J: Do not report certain kinds of exceptions to EA 2018-07-12 20:36:40 +03:00
Yan Zhulanow 4dfcb72fa1 Print source file location/contents if possible (EA-120038) 2018-06-08 19:37:20 +03:00
Yan Zhulanow 81f3346329 Evaluate: Fix annotation value evaluation (#KT-23058) 2018-04-02 19:16:46 +03:00
Natalia Selezneva 19e7002d02 Evaluate Expression: fix ClassNotFoundException for primitives and arrays 2018-02-14 14:40:31 +03:00
Natalia Selezneva dbd7ceb5fd Fix Evaluate Expression for inline functions from multifile package class.
Find main class generated for debugger by its name instead of relativePath length.
 #KT-22311 Fixed
2018-01-16 16:00:32 +03:00
Nikolay Krasko f39250c9a2 Fix irrelevant additional stops on breakpoint on line with inlines (KT-21945)
#KT-21945 Fixed
2017-12-26 12:46:45 +03:00
Nikolay Krasko 57d62eb74a Document error behaviour of evaluate expression lost sometime 2017-12-05 16:07:54 +03:00
Yan Zhulanow 43a1162b25 Evaluate: Fix for evaluating local variables captured by an inline function (KT-17514) 2017-10-16 21:25:44 +03:00
Yan Zhulanow 79b2b40289 Allow access to effectively invisible declarations in evaluator (KT-18775) 2017-09-15 17:54:46 +03:00
Nikolay Krasko 6d22e06359 Move all test data for single test to one directory 2017-06-13 19:14:48 +03:00
Mikhail Zarechenskiy e86d52b681 Fix return type of private members that return anonymous object
#KT-16813 Fixed

Anonymous objects returned from private-in-file members should behave as for private class members
2017-04-17 16:21:05 +03:00
Nikolay Krasko 42868b1364 Fix evaluate for internal functions (KT-15854)
#KT-15854 Fixed
2017-04-11 12:33:07 +03:00
Natalia Ukhorskaya 68f722b337 Debugger: fix evaluate expression when breakpoint is set on function without body inside object
#KT-15855 Fixed
2017-02-01 14:31:35 +03:00
Mikhael Bogdanov e1bec0df2e Proper generate interval for catch block variable; Fix for KT-15646: InconsistentDebugInfoException when stepping over throw
#KT-15646 Fixed
2017-01-19 09:33:10 +01:00
Natalia Ukhorskaya 01d4ec4187 Debugger: ability to set breakpoint to lambda in return statement (KT-14615)
#KT-14615 Fixed
2016-11-30 13:56:29 +03:00
Natalia Ukhorskaya d14136b0b6 Debugger: cannot call member extension in an object in Evaluate Expression
#KT-14822 Fixed
2016-11-26 00:20:43 +03:00
Denis Zharkov a9fcee098d Support single-underscore named variables in JVM backend
There are mainly two kind of changes:
- skipping 'componentX' calls for destructuring entries named _
- fixing local variable table for them
 - skip entries for destructuring entries named _
 - use $noName_<i> format for lambda parameters named _

 #KT-3824 Fixed
 #KT-2783 Fixed
2016-10-24 10:19:25 +03:00
Nikolay Krasko 944b9b5b6c Evaluate overloaded toString() in watches for Kotlin classes with delegate properties (KT-14068)
(cherry picked from commit 7774d2c)

 #KT-14068 Fixed
2016-10-17 15:16:46 +03:00
Denis Zharkov e75efc88ff Add support for desctructuring of lambda parameters in JVM backend
#KT-5828 In Progress
2016-09-19 20:22:57 +03:00
Natalia Ukhorskaya f6bb70aad1 Debugger: allow to evaluate 'this' and fields in java files 2016-08-16 09:08:34 +03:00
Natalia Ukhorskaya 6a04cd39b2 Debugger: allow to evaluate kotlin expressions in java files
#KT-7549 Fixed

 If the context is inside PsiJavaFile, get list of all local variables available in current frame (this logic was removed in 29778311e8 01.12.2015 Drop unnecesary logic about additional context for lambda in debugger). For each variable create KtProperty inside top-level KtFunction in KtFile and set it as contextElement for KtCodeFragment. This file should have all imports from PsiJavaFile. We do not create properties on top-level because they will be highlighted as top-level vals/vars.
2016-08-03 17:51:49 +03:00
Natalia Ukhorskaya d823d6f4ab Debugger tests: mark objects using NodeDescriptorImpl.getMarkup. Primitive values cannot be marked. 2016-08-03 17:51:49 +03:00
Natalia Ukhorskaya 3cbe28095b Debugger: check that label for marked object is a valid java identifier (KT-12651)
#KT-12651 Fixed
2016-07-19 17:52:55 +03:00
Nikolay Krasko eee45e91ce Add more tests for PropertyAccessorDescriptor.isDeafult() usages 2016-06-29 16:16:31 +03:00
Nikolay Krasko 4087e650aa Wrong delegation to delegation property in debugger when property defined in another module (KT-12678)
Different bytecode can be generated for delegated property and for non-delegated one. Backend inspects DELEGATED_PROPERTY_CALL to understand the property type, and expects that
this information had been already recorded into context. Frontend writes DELEGATED_PROPERTY_CALL into context during body resolve or type inference if type is not present.

Either way in debugger context it may happen that the DELEGATED_PROPERTY_CALL won't be written into context.

 #KT-12678
2016-06-20 16:22:04 +03:00