[patch][doc] Fix PR python/15613 (make gdb.GdbError formatting consistent with other exceptions

Phil Muldoon pmuldoon@redhat.com
Wed Sep 18 20:02:00 GMT 2013


This patch addresses PR 15613.  This makes the formatting of
gdb.GdbError more consistent with other exception types documented.

OK?

Cheers,

Phil


2013-09-18  Phil Muldoon  <pmuldoon@redhat.com>

	PR python/15613

	* gdb.texinfo (Exception Handling): Reorganize gdb.Error to be an
	item in a table instead of an findex.

--

diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo
index 60d2877..0796e45 100644
--- a/gdb/doc/gdb.texinfo
+++ b/gdb/doc/gdb.texinfo
@@ -23631,6 +23631,11 @@ NameError: name 'foo' is not defined
 Python code are converted to Python exceptions.  The type of the
 Python exception depends on the error.
 
+For the exceptions detailed below, your exception handler will see the
+@value{GDBN} error message as its value and the Python call stack
+backtrace at the Python statement closest to where the @value{GDBN}
+error occurred as the traceback.
+
 @ftable @code
 @item gdb.error
 This is the base class for most exceptions generated by @value{GDBN}.
@@ -23649,12 +23654,11 @@ User interrupt (via @kbd{C-c} or by typing @kbd{q} at a pagination
 prompt) is translated to a Python @code{KeyboardInterrupt} exception.
 @end ftable
 
-In all cases, your exception handler will see the @value{GDBN} error
-message as its value and the Python call stack backtrace at the Python
-statement closest to where the @value{GDBN} error occured as the
-traceback.
+Some exceptions types will not trigger a traceback to be printed in
+@value{GDBN}.  The table below details these types of exception.
 
-@findex gdb.GdbError
+@ftable @code
+@item gdb.GdbError
 When implementing @value{GDBN} commands in Python via @code{gdb.Command},
 it is useful to be able to throw an exception that doesn't cause a
 traceback to be printed.  For example, the user may have invoked the
@@ -23677,6 +23681,7 @@ to handle this case.  Example:
 (gdb) hello-world 42
 hello-world takes no arguments
 @end smallexample
+@end ftable
 
 @node Values From Inferior
 @subsubsection Values From Inferior

	



More information about the Gdb-patches mailing list