This is the mail archive of the
archer@sourceware.org
mailing list for the Archer project.
Re: feature idea: type nicknames
- From: Tom Tromey <tromey at redhat dot com>
- To: Roland McGrath <roland at redhat dot com>
- Cc: Project Archer <archer at sourceware dot org>
- Date: Fri, 03 Jul 2009 10:34:32 -0600
- Subject: Re: feature idea: type nicknames
- References: <20090703002049.C49F1404FD@magilla.sf.frob.com>
- Reply-to: Tom Tromey <tromey at redhat dot com>
>>>>> "Roland" == Roland McGrath <roland@redhat.com> writes:
[...]
Roland> appears in *my* code nowhere in a form longer than:
Roland> std::map<int, elfutils::dwarf_data::attr_value<elfutils::dwarf_edit, elfutils::dwarf_data::value<elfutils::dwarf_edit> > >::const_iterator
We looked into this particular sub-problem a little. Our idea was
that it would be nice if "ptype x" showed exactly what the user wrote
in the declaration of "x".
In the end it seems that GCC usually emits the verbose forms. I filed
a gcc bug report about this; but it isn't completely clear that this
is what we actually want (see last comment):
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37590
Another idea would be to suppress printing of defaulted template
parameters by default. I don't think we've researched that yet. (I
assume we'll get into the usual problems: DWARF still can't represent
everything, and anyway even if it could, GCC doesn't emit it :-)
Roland> What makes sense to me is that the STL pretty printer module can also
Roland> have "type name pretty-printers".
Interesting idea. Maybe it is time to resurrect the currently-defunct
type-printing task.
Tom