public inbox for archer-commits@sourceware.org
help / color / mirror / Atom feed
* [SCM]  archer-pmuldoon-python-backtrace: Fix coding nits and correct a comment
@ 2013-02-26 19:10 pmuldoon
  0 siblings, 0 replies; only message in thread
From: pmuldoon @ 2013-02-26 19:10 UTC (permalink / raw)
  To: archer-commits

The branch, archer-pmuldoon-python-backtrace has been updated
       via  3920788b2863520474fb37b4b333edee8cae84d0 (commit)
      from  29c6fb0276468dd53fd6b418e9e406173699413c (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email.

- Log -----------------------------------------------------------------
commit 3920788b2863520474fb37b4b333edee8cae84d0
Author: Phil Muldoon <pmuldoon@redhat.com>
Date:   Tue Feb 26 19:10:24 2013 +0000

    Fix coding nits and correct a comment

-----------------------------------------------------------------------

Summary of changes:
 gdb/python/lib/gdb/command/frame_filters.py |   26 +++++++++++++-------------
 gdb/python/py-framefilter.c                 |   22 ++++++++++++----------
 gdb/python/python.c                         |    6 +++---
 3 files changed, 28 insertions(+), 26 deletions(-)

First 500 lines of diff:
diff --git a/gdb/python/lib/gdb/command/frame_filters.py b/gdb/python/lib/gdb/command/frame_filters.py
index f5d5f1d..ea10f4e 100644
--- a/gdb/python/lib/gdb/command/frame_filters.py
+++ b/gdb/python/lib/gdb/command/frame_filters.py
@@ -199,9 +199,9 @@ class InfoFrameFilter(gdb.Command):
            specified by GDB user commands.
         """
 
-        sorted_frame_filters = sorted (frame_filters.items(),
-                                       key=lambda i: _get_priority(i[1]),
-                                       reverse=True)
+        sorted_frame_filters = sorted(frame_filters.items(),
+                                      key=lambda i: _get_priority(i[1]),
+                                      reverse=True)
 
         print "  Priority  Enabled  Name"
         print "  ========  =======  ===="
@@ -261,7 +261,7 @@ def _do_enable_frame_filter(command_tuple, flag):
 
     _set_enabled(ff, flag)
 
-def _complete_frame_filter_list (text, word):
+def _complete_frame_filter_list(text, word):
     """Worker for frame filter dictionary name completion.
 
     Arguments:
@@ -294,7 +294,7 @@ def _complete_frame_filter_list (text, word):
     # dictioanries that the previous filter operation returned.
     return flist
 
-def _complete_frame_filter_name (word, printer_dict):
+def _complete_frame_filter_name(word, printer_dict):
     """Worker for frame filter name completion.
 
     Arguments:
@@ -332,13 +332,13 @@ class EnableFrameFilter(gdb.Command):
     def __init__(self):
         super(EnableFrameFilter, self).__init__("enable frame-filter",
                                                  gdb.COMMAND_DATA)
-    def complete (self,text,word):
+    def complete(self,text,word):
         """Completion function for both frame filter dictionary, and
         frame filter name."""
         if text.count(" ") == 0:
             return _complete_frame_filter_list(text,word)
         else:
-            printer_list = _return_list (text.split()[0].rstrip())
+            printer_list = _return_list(text.split()[0].rstrip())
             return _complete_frame_filter_name(word, printer_list)
 
     def invoke(self, arg, from_tty):
@@ -363,13 +363,13 @@ class DisableFrameFilter(gdb.Command):
         super(DisableFrameFilter, self).__init__("disable frame-filter",
                                                   gdb.COMMAND_DATA)
 
-    def complete (self,text,word):
+    def complete(self,text,word):
         """Completion function for both frame filter dictionary, and
         frame filter name."""
         if text.count(" ") == 0:
             return _complete_frame_filter_list(text,word)
         else:
-            printer_list = _return_list (text.split()[0].rstrip())
+            printer_list = _return_list(text.split()[0].rstrip())
             return _complete_frame_filter_name(word, printer_list)
 
     def invoke(self, arg, from_tty):
@@ -443,13 +443,13 @@ class SetFrameFilterPriority(gdb.Command):
 
         _set_priority(ff, priority)
 
-    def complete (self,text,word):
+    def complete(self,text,word):
         """Completion function for both frame filter dictionary, and
         frame filter name."""
         if text.count(" ") == 0:
             return _complete_frame_filter_list(text,word)
         else:
-            printer_list = _return_list (text.split()[0].rstrip())
+            printer_list = _return_list(text.split()[0].rstrip())
             return _complete_frame_filter_name(word, printer_list)
 
     def invoke(self, arg, from_tty):
@@ -525,14 +525,14 @@ class ShowFrameFilterPriority(gdb.Command):
 
         return _get_priority(ff)
 
-    def complete (self,text,word):
+    def complete(self,text,word):
         """Completion function for both frame filter dictionary, and
         frame filter name."""
 
         if text.count(" ") == 0:
             return _complete_frame_filter_list(text,word)
         else:
-            printer_list = _return_list (text.split()[0].rstrip())
+            printer_list = _return_list(text.split()[0].rstrip())
             return _complete_frame_filter_name(word, printer_list)
 
     def invoke(self, arg, from_tty):
diff --git a/gdb/python/py-framefilter.c b/gdb/python/py-framefilter.c
index 3e075a8..bd8cafa 100644
--- a/gdb/python/py-framefilter.c
+++ b/gdb/python/py-framefilter.c
@@ -273,7 +273,7 @@ py_print_value (struct ui_out *out, struct value *val,
 	}
       if (except.reason > 0)
 	{
-	  gdbpy_convert_exception(except);
+	  gdbpy_convert_exception (except);
 	  return PY_BT_ERROR;
 	}
     }
@@ -768,7 +768,7 @@ enumerate_locals (PyObject *iter,
       do_cleanups (cleanups);
     }
 
-  if (! item && PyErr_Occurred())
+  if (! item && PyErr_Occurred ())
     goto error;
 
   return 1;
@@ -1332,14 +1332,16 @@ bootstrap_python_frame_filters (struct frame_info *frame, int
 /*  This is the only publicly exported function in this file.  FRAME
     is the source frame to start frame-filter invocation.  FLAGS is an
     integer holding the flags for printing.  The following elements of
-    the FRAME_FILTER_FLAGS enum denotes makeup of FLAGS: PRINT_LEVEL
-    is a flag indicating whether to print the frame's relative level
-    in the output.  PRINT_FRAME_INFO is a flag that indicates whether
-    this function should print the frame information, PRINT_ARGS is a
-    flag that indicates whether to print frame arguments, and
-    PRINT_LOCALS, likewise, with frame local variables.  ARGS_TYPE is
-    an enumerater describing the argument format, OUT is the output
-    stream to print, and COUNT is a the number of frames to print.  */
+    the FRAME_FILTER_FLAGS enum denotes the make-up of FLAGS:
+    PRINT_LEVEL is a flag indicating whether to print the frame's
+    relative level in the output.  PRINT_FRAME_INFO is a flag that
+    indicates whether this function should print the frame
+    information, PRINT_ARGS is a flag that indicates whether to print
+    frame arguments, and PRINT_LOCALS, likewise, with frame local
+    variables.  ARGS_TYPE is an enumerator describing the argument
+    format, OUT is the output stream to print.  FRAME_LOW is the
+    beginning of the slice of frames to print, and FRAME_HIGH is the
+    upper limit of the frames to count.  */
 
 int apply_frame_filter (struct frame_info *frame, int flags,
 			enum py_frame_args args_type,
diff --git a/gdb/python/python.c b/gdb/python/python.c
index ee4da19..999419d 100644
--- a/gdb/python/python.c
+++ b/gdb/python/python.c
@@ -1382,9 +1382,9 @@ free_type_printers (void *arg)
 }
 
 int apply_frame_filter (struct frame_info *frame, int flags,
-			enum print_values mi_print_args_type,
-			const char *cli_print_frame_args_type,
-			struct ui_out *out, int count)
+			enum py_frame_args args_type,
+			struct ui_out *out, int frame_low,
+			int frame_high)
 {
   return PY_BT_NO_FILTERS;
 }


hooks/post-receive
--
Repository for Project Archer.


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2013-02-26 19:10 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-02-26 19:10 [SCM] archer-pmuldoon-python-backtrace: Fix coding nits and correct a comment pmuldoon

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).