Re: [2/2] Inspect extra signal information

Paul Pluzhnikov
2009-04-06T19:00:04Z

[-- Attachment #1: Type: text/plain, Size: 619 bytes --]

On Mon, Feb 9, 2009 at 3:16 PM, Pedro Alves <pedro@codesourcery.com> wrote:

> I'm not 100% sure if we want to fix this, or if we want to
> adjust the testsuite instead, and making clear in the docs
> that the variable can be empty.

Meanwhile the test continues to fail :-(

Attached is a proposed cleanup.

Thanks,
--
Paul Pluzhnikov

testsuite/ChangeLog
2009-04-06 Paul Pluzhnikov <ppluzhnikov@google.com>

* gdb.base/default.exp: Fix "show convenience".

doc/ChangeLog
2009-04-06 Paul Pluzhnikov <ppluzhnikov@google.com>

* gdb.texinfo (convenince variables): Mention
$_siginfo could be empty.

[-- Attachment #2: gdb-convenience.20090406.txt --]
[-- Type: text/plain, Size: 1796 bytes --]

Index: testsuite/gdb.base/default.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.base/default.exp,v
retrieving revision 1.29
diff -u -p -u -r1.29 default.exp
--- testsuite/gdb.base/default.exp 3 Jan 2009 05:58:03 -0000 1.29
+++ testsuite/gdb.base/default.exp 6 Apr 2009 18:43:46 -0000
@@ -598,7 +598,7 @@ gdb_test "show complaints" "Max number o
#test show confirm
gdb_test "show confirm" "Whether to confirm potentially dangerous operations is o\[a-z\]*." "show confirm"
#test show convenience
-gdb_test "show convenience" "No debugger convenience variables now defined.(\[^\r\n\]*\[\r\n\])+Convenience variables have names starting with \".\";(\[^\r\n\]*\[\r\n\])+use \"set\" as in \"set .foo = 5\" to define them." "show convenience"
+gdb_test "show convenience" "\\\$_siginfo = void" "show convenience"
#test show directories
gdb_test "show directories" "Source directories searched: .cdir\[:;\].cwd" "show directories"
#test show editing
Index: doc/gdb.texinfo
===================================================================
RCS file: /cvs/src/src/gdb/doc/gdb.texinfo,v
retrieving revision 1.578
diff -u -p -u -r1.578 gdb.texinfo
--- doc/gdb.texinfo 2 Apr 2009 15:56:08 -0000 1.578
+++ doc/gdb.texinfo 6 Apr 2009 18:43:47 -0000
@@ -7445,7 +7448,9 @@ the program being debugged terminates.
@item $_siginfo
@vindex $_siginfo@r{, convenience variable}
The variable @code{$_siginfo} is bound to extra signal information
-inspection (@pxref{extra signal information}).
+inspection (@pxref{extra signal information}). Note that @code{$_siginfo}
+could be empty. For example, it will be empty before you execute the
+@code{run} command.
@end table

On HP-UX systems, if you refer to a function or variable name that