Expression Evaluation in DSF/TCF [message #1748636] |
Fri, 25 November 2016 09:13  |
Eclipse User |
|
|
|
Hi,
I have been working on a module that interacts with the Eclipse debugger programmatically.
So far I have been able to perform all the required actions I have needed without having to invoke any implementation specific code, and this has worked with the CDT/DSF/TCF debugger.
However, I am now attempting to access expressions vie the IExpressionsManager interface and this seems to be problematic with the TCF debugger.
While I am able to add IExpression objects to the "expressions" view via the IExpressionsManager, and the values in the view are displayed properly, The IExpression object I have has a null value and context.
I found the following code in TCFNodeExpression.Java which seems to attempt to deal with this, however after observing execution, it seems that Object returned by the getDebugContext() method is a TCFNodeExecContext, which does not implement IDebugElement or ILaunch, and as such the IExpression context remains null.

Is there some other way for me to get an expression's value without having to specifically invoke a TCFTask?
Thanks
Attachment: image001.png
(Size: 12.56KB, Downloaded 480 times)
|
|
|
Re: Expression Evaluation in DSF/TCF [message #1748799 is a reply to message #1748636] |
Mon, 28 November 2016 14:02  |
Eclipse User |
|
|
|
In TCF, IExpression.getValue(), IValue, IVariable are not supported. setExpressionContext() call appears to be result of sloppy copy/pasting. You have to use ITCFExpression.getValue() method to get value of the expression.
|
|
|
Powered by
FUDForum. Page generated in 0.02971 seconds