public inbox for archer-commits@sourceware.org help / color / mirror / Atom feed
From: pmuldoon@sourceware.org To: archer-commits@sourceware.org Subject: [SCM] pmuldoon/python-backtrace: Use set/show frame-filter over set/show python frame-filter Date: Thu, 11 Apr 2013 13:57:00 -0000 [thread overview] Message-ID: <20130411135753.5399.qmail@sourceware.org> (raw) The branch, pmuldoon/python-backtrace has been updated via 81259914c748edc7ccba84fb00f3f5926d785c78 (commit) from 0cb454caccab3d459a8db960d65246391572695c (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email. - Log ----------------------------------------------------------------- commit 81259914c748edc7ccba84fb00f3f5926d785c78 Author: Phil Muldoon <pmuldoon@redhat.com> Date: Thu Apr 11 14:57:12 2013 +0100 Use set/show frame-filter over set/show python frame-filter ----------------------------------------------------------------------- Summary of changes: gdb/python/lib/gdb/command/frame_filters.py | 37 ++++++++++++++------------- gdb/testsuite/gdb.python/py-framefilter.exp | 6 ++-- 2 files changed, 22 insertions(+), 21 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 78cbeea..e1800f6 100644 --- a/gdb/python/lib/gdb/command/frame_filters.py +++ b/gdb/python/lib/gdb/command/frame_filters.py @@ -28,15 +28,16 @@ class SetFilterPrefixCmd(gdb.Command): """Prefix command for 'set' frame-filter related operations.""" def __init__(self): - super(SetFilterPrefixCmd, self).__init__("set python frame-filter", - gdb.COMMAND_DATA, - gdb.COMPLETE_COMMAND, True) + super(SetFilterPrefixCmd, self).__init__("set frame-filter", + gdb.COMMAND_OBSCURE, + gdb.COMPLETE_NONE, True) + class ShowFilterPrefixCmd(gdb.Command): """Prefix command for 'show' frame-filter related operations.""" def __init__(self): - super(ShowFilterPrefixCmd, self).__init__("show python frame-filter", - gdb.COMMAND_DATA, - gdb.COMPLETE_COMMAND, True) + super(ShowFilterPrefixCmd, self).__init__("show frame-filter", + gdb.COMMAND_OBSCURE, + gdb.COMPLETE_NONE, True) class InfoFrameFilter(gdb.Command): """List all registered Python frame-filters. @@ -280,7 +281,7 @@ class DisableFrameFilter(gdb.Command): class SetFrameFilterPriority(gdb.Command): """GDB command to set the priority of the specified frame-filter. - Usage: set python frame-filter priority DICTIONARY NAME PRIORITY + Usage: set frame-filter priority DICTIONARY NAME PRIORITY DICTIONARY is the name of the frame filter dictionary on which to operate. Named dictionaries are: "global" for the global frame @@ -295,8 +296,8 @@ class SetFrameFilterPriority(gdb.Command): """ def __init__(self): - super(SetFrameFilterPriority, self).__init__("set python " \ - "frame-filter priority", + super(SetFrameFilterPriority, self).__init__("set frame-filter " \ + "priority", gdb.COMMAND_DATA) def _parse_pri_arg(self, arg): @@ -316,8 +317,8 @@ class SetFrameFilterPriority(gdb.Command): argv = gdb.string_to_argv(arg); argc = len(argv) if argc != 3: - raise gdb.GdbError("set python frame-filter priority " \ - "takes exactly three arguments.") + raise gdb.GdbError("set frame-filter priority " \ + "takes exactly three arguments.") return argv @@ -361,7 +362,7 @@ class SetFrameFilterPriority(gdb.Command): class ShowFrameFilterPriority(gdb.Command): """GDB command to show the priority of the specified frame-filter. - Usage: show python frame-filter priority DICTIONARY NAME + Usage: show frame-filter priority DICTIONARY NAME DICTIONARY is the name of the frame filter dictionary on which to operate. Named dictionaries are: "global" for the global frame @@ -373,8 +374,8 @@ class ShowFrameFilterPriority(gdb.Command): """ def __init__(self): - super(ShowFrameFilterPriority, self).__init__("show python " \ - "frame-filter priority", + super(ShowFrameFilterPriority, self).__init__("show frame-filter " \ + "priority", gdb.COMMAND_DATA) def _parse_pri_arg(self, arg): @@ -394,8 +395,8 @@ class ShowFrameFilterPriority(gdb.Command): argv = gdb.string_to_argv(arg); argc = len(argv) if argc != 2: - raise gdb.GdbError("show python frame-filter priority " \ - "takes exactly two arguments.") + raise gdb.GdbError("show frame-filter priority " \ + "takes exactly two arguments.") return argv @@ -445,10 +446,10 @@ class ShowFrameFilterPriority(gdb.Command): print("Priority of filter '" + filter_name + "' in list '" \ + list_name + "' is: " + str(priority)) - -InfoFrameFilter() +# Register commands SetFilterPrefixCmd() ShowFilterPrefixCmd() +InfoFrameFilter() EnableFrameFilter() DisableFrameFilter() SetFrameFilterPriority() diff --git a/gdb/testsuite/gdb.python/py-framefilter.exp b/gdb/testsuite/gdb.python/py-framefilter.exp index 44dcbe7..6a11c43 100644 --- a/gdb/testsuite/gdb.python/py-framefilter.exp +++ b/gdb/testsuite/gdb.python/py-framefilter.exp @@ -75,10 +75,10 @@ gdb_test "info frame-filter" \ ".*900.*Yes.*Elider.*100.*Yes.*Reverse.*10.*.*No.*Object.*1.*" # Test set/show -gdb_test "show python frame-filter priority global Elider" \ +gdb_test "show frame-filter priority global Elider" \ "Priority of filter 'Elider' in list 'global' is: 900" -gdb_test_no_output "set python frame-filter priority global Elider 1000" -gdb_test "show python frame-filter priority global Elider" \ +gdb_test_no_output "set frame-filter priority global Elider 1000" +gdb_test "show frame-filter priority global Elider" \ "Priority of filter 'Elider' in list 'global' is: 1000" gdb_test "info frame-filter" \ ".*1000.*Yes.*Elider.*100.*Yes.*Reverse.*10.*.*No.*Object.*1.*" hooks/post-receive -- Repository for Project Archer.
reply other threads:[~2013-04-11 13:57 UTC|newest] Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20130411135753.5399.qmail@sourceware.org \ --to=pmuldoon@sourceware.org \ --cc=archer-commits@sourceware.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
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).