This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH] Improve "skip file X" behaviour to allow quiet adding of skip entries in .gdbinit
- From: Pedro Alves <palves at redhat dot com>
- To: Richard Geary <richardg dot work at gmail dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Tue, 13 Aug 2013 16:12:57 +0100
- Subject: Re: [PATCH] Improve "skip file X" behaviour to allow quiet adding of skip entries in .gdbinit
- References: <CAMWPO3XjOsO0i3JkgjbAFCvX3+PyrVQWVoQ0K2Yv3npiiiSTFA at mail dot gmail dot com>
First off, thanks.
On 08/10/2013 03:21 PM, Richard Geary wrote:
> - Change the default answer to the "Ignore..." question to Y.
> - When run as a server command, hide the "No source file named "...
> message to allow the user to quietly add skip entries
Unfortunately, this conflates more than one orthogonal change. Each
should be driven by their own rationale, as separate patches/posts.
For the first change, you'll need to argue why "y" is a better default.
Please note also <http://sourceware.org/bugzilla/show_bug.cgi?id=15800>.
For the second change, you'll need to argue why "server" is the
proper fit here. Suppressing output is not how "server" behaves
in any other case, AFAICS. A frontend using it does want to see
the sub command's output to be able to know what happened.
>From the code:
/* Nonzero if the current command is modified by "server ". This
affects things like recording into the command history, commands
repeating on RETURN, etc. This is so a user interface (emacs, GUI,
whatever) can issue its own commands and also send along commands
from the user, and have the user not notice that the user interface
is issuing commands too. */
and from the manual:
To issue a command to @value{GDBN} without affecting certain aspects of
the state which is seen by users, prefix it with @samp{server }
(@pxref{Server Prefix}). This
means that this command will not affect the command history, nor will it
affect @value{GDBN}'s notion of which command to repeat if @key{RET} is
pressed on a line by itself.
(Naturally, the frontend will hide the command's output from the user
somehow.)
--
Pedro Alves