Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 344702 - [cdt] Provide "Add Watchpoint" in Editor, Variables and Expressions view
Summary: [cdt] Provide "Add Watchpoint" in Editor, Variables and Expressions view
Status: RESOLVED FIXED
Alias: None
Product: TCF
Classification: Tools
Component: Debug (show other bugs)
Version: 0.3   Edit
Hardware: All All
: P3 enhancement (vote)
Target Milestone: 0.4.0   Edit
Assignee: Project Inbox CLA
QA Contact: Eugene Tarassov CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-05-04 09:44 EDT by Anton Leherbauer CLA
Modified: 2014-05-02 09:22 EDT (History)
1 user (show)

See Also:


Attachments
Patch (19.34 KB, patch)
2011-05-04 09:44 EDT, Anton Leherbauer CLA
aleherb+eclipse: iplog-
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Anton Leherbauer CLA 2011-05-04 09:44:58 EDT
Created attachment 194714 [details]
Patch

This patch adds "Add Watchpoint" menu items to the Editor and Variables and Expressions view.
For the Variables and Expressions view we reuse the CDT action.  For the editor we contribute a command handler restricted to TCF, i.e. the menu item is only visible when a TCF session is active.
Comment 1 Eugene Tarassov CLA 2011-05-04 17:26:08 EDT
Could you comment on changes in TCFNodeExpression class?

The new cache item "expression_text" seems to compute same data as "text" with only minor difference. Actually "text" seems doing it a little bit better. Can we reuse "text" instead of "expression_text"?
Comment 2 Anton Leherbauer CLA 2011-05-05 03:26:34 EDT
(In reply to comment #1)
> Could you comment on changes in TCFNodeExpression class?
> 
> The new cache item "expression_text" seems to compute same data as "text" with
> only minor difference. Actually "text" seems doing it a little bit better. Can
> we reuse "text" instead of "expression_text"?

I did try with "text" first, but it does not include the parent expression and it does not resolve symbol names.
Comment 3 Anton Leherbauer CLA 2011-05-05 04:40:56 EDT
Sorry, the changes are already committed, because I did not get a notification from bugzilla about your comment.  I'll leave the bug open for now.
Comment 4 Eugene Tarassov CLA 2011-05-05 22:31:55 EDT
> ... it does not resolve symbol names.

If you mean it uses IDs instead of names - it is intensional. Names can be ambiguous. IDs instead of names is an extension of the expression syntax. Anyway, I think it is OK for now. I will have another look at the code when I have more time.
Comment 5 Anton Leherbauer CLA 2014-05-02 09:22:03 EDT
I think this can be closed now.