Discussion:
[PATCH 0/2] Two trivial output changes
Tom Tromey
2018-11-07 04:56:22 UTC
Permalink
I noticed a couple of gdb output oddities, both fixed here. No new
tests due to their triviality. Tested by the buildbot.

Tom
Tom Tromey
2018-11-07 04:56:24 UTC
Permalink
This changes require_record_target to say "<TAB>" rather than "<tab>".
I think capitalizing here is a bit more GNU-ish, based on Emacs usage
and one other case in gdb.

gdb/ChangeLog
2018-11-06 Tom Tromey <***@tromey.com>

* record.c (require_record_target): Upper-case "<TAB>".
---
gdb/ChangeLog | 4 ++++
gdb/record.c | 2 +-
2 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/gdb/record.c b/gdb/record.c
index 2fd77824d4..fdc76f80cc 100644
--- a/gdb/record.c
+++ b/gdb/record.c
@@ -75,7 +75,7 @@ require_record_target (void)
t = find_record_target ();
if (t == NULL)
error (_("No record target is currently active.\n"
- "Use one of the \"target record-<tab><tab>\" commands first."));
+ "Use one of the \"target record-<TAB><TAB>\" commands first."));

return t;
}
--
2.17.2
Tom Tromey
2018-11-07 04:56:23 UTC
Permalink
I noticed that "info pretty-printers" will indent the "objfile" line
like:

(top-gdb) info pretty-printer
global pretty-printers:
builtin
mpx_bound128
objfile /home/tromey/gdb/build/gdb/gdb pretty-printers:
type_lookup_function

I think the "objfile" line should be "out-dented", following the same
style as the "global" and "progspace" (not shown) lines.

This patch implements this.

gdb/ChangeLog
2018-11-06 Tom Tromey <***@tromey.com>

* python/lib/gdb/command/pretty_printers.py
(InfoPrettyPrinter.invoke): Don't indent "objfile" heading.
---
gdb/ChangeLog | 5 +++++
gdb/python/lib/gdb/command/pretty_printers.py | 2 +-
2 files changed, 6 insertions(+), 1 deletion(-)

diff --git a/gdb/python/lib/gdb/command/pretty_printers.py b/gdb/python/lib/gdb/command/pretty_printers.py
index 429505f93e..9788218942 100644
--- a/gdb/python/lib/gdb/command/pretty_printers.py
+++ b/gdb/python/lib/gdb/command/pretty_printers.py
@@ -158,7 +158,7 @@ printer-name;subprinter-name."""
cp.pretty_printers, "progspace",
object_re, name_re, subname_re)
for objfile in gdb.objfiles():
- self.invoke1(" objfile %s pretty-printers:" % objfile.filename,
+ self.invoke1("objfile %s pretty-printers:" % objfile.filename,
objfile.pretty_printers, objfile.filename,
object_re, name_re, subname_re)
--
2.17.2
Simon Marchi
2018-11-07 14:55:52 UTC
Permalink
Post by Tom Tromey
I noticed a couple of gdb output oddities, both fixed here. No new
tests due to their triviality. Tested by the buildbot.
Tom
Both LGTM.

Simon

Loading...