From: Doug Evans <dje@google.com>
To: gdb-patches@sourceware.org
Subject: Re: [RFA, doc RFA]: New printing module and info/disable/enable commands
Date: Mon, 01 Nov 2010 15:09:00 -0000 [thread overview]
Message-ID: <AANLkTinHR1=pS4VpARg5YWnanW72oKi-EMs+OuRUB_4E@mail.gmail.com> (raw)
In-Reply-To: <20101101024704.6A4AA2461AF@ruffy.mtv.corp.google.com>
On Sun, Oct 31, 2010 at 7:47 PM, Doug Evans <dje@google.com> wrote:
> Hi.
>
> This patch adds two things: A new python module to assist in writing
> pretty-printers (mostly to formalize some of the administrivia aspects
> to support the new commands), and three new commands:
> info|enable|disable pretty-printer.
>
> This is a revised version of the patch I posted earlier
> (several months ago IIRC).
>
> Ok to check in?
>
> 2010-10-31 Doug Evans <dje@google.com>
>
> New python module gdb.printing, and new commands info pretty-printer,
> enable pretty-printer, disable pretty-printer.
> * NEWS: Mention them.
> * data-directory/Makefile.in (PYTHON_FILES): Add gdb/printing.py,
> gdb/command/__init__.py, gdb/command/pretty_printers.py.
> * python/lib/gdb/__init__.py: Install pretty-printer commands.
> * python/lib/gdb/printing.py: New file.
> * python/lib/gdb/command/__init__.py: New file.
> * python/lib/gdb/command/pretty_printers.py: New file.
>
> doc/
> * gdb.texinfo (Pretty Printing): Expand into three sections,
> introduction, example, and commands.
> (Python API): Delete section Disabling Pretty-Printers, merge into
> Selecting Pretty-Printers.
> (Writing a Pretty-Printer): New section. Move the pretty-printer
> example here, and reformat to match python coding style. Add a second
> example using the gdb.printing module.
> (Python modules): Add gdb.printing.
>
> testsuite/
> * gdb.python/py-pp-maint.c: New file.
> * gdb.python/py-pp-maint.exp: New file.
> * gdb.python/py-pp-maint.py: New file.
There's one aspect of the coding standards that I violate here, which
I forgot to mention and bring up for discussion.
I added this to the python coding standards in gdbint.texinfo based on
discussions in IRC:
"Use @code{FIXME} instead of @code{TODO}."
There are two issues with this:
- the meaning of the two words can be quite different
- new FIXMEs are prohibited in gdb in the first place
This raises two questions:
1) What's the proper way to document thoughts on future improvements?
This matters to the current patch here:
+ def list_pretty_printers(self, pretty_printers, name_re, subname_re):
+ """Print a list of pretty-printers."""
+ # TODO: Provide option to list printers in "lookup order"
+ # (i.e. unsorted).
The option is not present in the current patch for fear of feechuritis.
2) Should I reword the above text in gdbint.texinfo to say
"TODO is prohibited." ?
prev parent reply other threads:[~2010-11-01 15:09 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-11-01 2:47 Doug Evans
2010-11-01 4:07 ` Eli Zaretskii
2010-11-02 17:35 ` Doug Evans
2010-11-02 20:31 ` Tom Tromey
2010-11-01 15:09 ` Doug Evans [this message]
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='AANLkTinHR1=pS4VpARg5YWnanW72oKi-EMs+OuRUB_4E@mail.gmail.com' \
--to=dje@google.com \
--cc=gdb-patches@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: link
Be 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