Debugger: should expressionUnderCursor use the DUCain?
David Nolden
zwabel at googlemail.com
Sun Mar 21 12:48:04 UTC 2010
Am Sonntag 21 März 2010 12:41:09 schrieb Niko Sams:
> Hi,
>
> The current implementation of
> VariableController::expressionUnderCursor (should return
> the string of the variable that should be shown in the variable
> tooltip) parses the text
> manually.
> Thow issues with this implementation:
> - it's buggy (https://bugs.kde.org/show_bug.cgi?id=231466) - but that
> can be fixed
> - it shows the popup for basically everyting (functions, macros, even
> comments) while it should
> only for variables (we could simply ignore this)
>
> And we have the data in the DUChain - why not use it; a simple
> findContextAt and findDeclarationAt
> should do it.
>
> Issues:
> - it only works when the file is parsed correctly (projects may not be
> setup correctly etc)
> - gdb supports much more than just c/c++ (but atm we don't)
>
> Any comments on this?
I guess the best thing would be if the duchain was used as an optional
"helper" to either reject or manipulate the tooltip requests, and use the
current implementation as fallback.
Greetings, David
More information about the KDevelop-devel
mailing list