Discussion:
[Bug tui/17849] New: Showing local variables in gdb tui window
hlin117 at gmail dot com
2015-01-17 17:40:58 UTC
Permalink
https://sourceware.org/bugzilla/show_bug.cgi?id=17849

Bug ID: 17849
Summary: Showing local variables in gdb tui window
Product: gdb
Version: unknown
Status: NEW
Severity: enhancement
Priority: P2
Component: tui
Assignee: unassigned at sourceware dot org
Reporter: hlin117 at gmail dot com

Created attachment 8068
--> https://sourceware.org/bugzilla/attachment.cgi?id=8068&action=edit
An image of lldb's gui, while a program is running.

In gdb, a user could input `info locals` to show the current local variables,
but it would be convenient if in tui mode, we could see the local variables in
a separate window.

Furthermore, it would be convenient if a user could see the attributes of an
object, if an object is a local variable.

lldb somewhat already implements this feature, when you run lldb's gui. lldb's
gui is not officially documented, nor is it the main focus of lldb's
production. However, some of the functionality is there, and it would be nice
if gdb implemented this functionality as well.
--
You are receiving this mail because:
You are on the CC list for the bug.
palves at redhat dot com
2015-07-02 14:11:03 UTC
Permalink
https://sourceware.org/bugzilla/show_bug.cgi?id=17849

Pedro Alves <palves at redhat dot com> changed:

What |Removed |Added
----------------------------------------------------------------------------
CC| |palves at redhat dot com

--- Comment #1 from Pedro Alves <palves at redhat dot com> ---
Agreed. There's lot of neat stuff we could do with the TUI, but, as always, it
takes someone motivated enough to go and do it. *hint, hint*
--
You are receiving this mail because:
You are on the CC list for the bug.
tromey at sourceware dot org
2018-09-02 23:17:04 UTC
Permalink
https://sourceware.org/bugzilla/show_bug.cgi?id=17849

Tom Tromey <tromey at sourceware dot org> changed:

What |Removed |Added
----------------------------------------------------------------------------
CC| |tromey at sourceware dot org

--- Comment #2 from Tom Tromey <tromey at sourceware dot org> ---
What if instead of a dedicated local variable window,
there was a command to add a new window which ran a gdb
command on each stop. This would allow for a "bt" window
or an "info locals" window. (And perhaps we could add
some new command to be like "info locals + args")
--
You are receiving this mail because:
You are on the CC list for the bug.
palves at redhat dot com
2018-09-03 05:55:45 UTC
Permalink
https://sourceware.org/bugzilla/show_bug.cgi?id=17849

--- Comment #3 from Pedro Alves <palves at redhat dot com> ---
I think a dedicated window can be more powerful for this use case, because it
can for example support expanding/contracting structure children (TUI mouse
support would go along nicely with it), and could also highlight when a
variable changes value compared to the previous stop, like the registers window
does. I would imagine a "locals" window to be a special case of a "display /
watch any expression" window though, could even be the same window.
--
You are receiving this mail because:
You are on the CC list for the bug.
tromey at sourceware dot org
2018-09-08 14:43:54 UTC
Permalink
https://sourceware.org/bugzilla/show_bug.cgi?id=17849

--- Comment #4 from Tom Tromey <tromey at sourceware dot org> ---
I was thinking of just simple text diffing of some kind.

The main problem with, say, using varobj for this display is
that then you lose all the language-specific formatting.
Maybe that is ok though.

Or maybe it could use value_print, but do textual diffing
on a per-variable basis.
--
You are receiving this mail because:
You are on the CC list for the bug.
Loading...