Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: "André Pönitz" <andre.poenitz@nokia.com>
To: gdb@sourceware.org
Subject: Re: Robustifying pretty-printers
Date: Tue, 16 Jun 2009 07:22:00 -0000	[thread overview]
Message-ID: <200906160922.33025.andre.poenitz@nokia.com> (raw)
In-Reply-To: <200906151725.31749.vladimir@codesourcery.com>

On Monday 15 June 2009 15:25:31 Vladimir Prus wrote:
> On Monday 15 June 2009 Daniel Jacobowitz wrote:
> 
> > On Mon, Jun 15, 2009 at 04:38:57PM +0400, Vladimir Prus wrote:
> > > On Monday 15 June 2009 Phil Muldoon wrote:
> > > > + return self.val['_M_dataplus']['_M_p'].string (encoding, length = len)
> > > 
> > > Great, this is exactly what I was looking for.
> > 
> > Is it?  This uses the length from the (possibly uninitialized)
> > std::string as a maximum.  I think we want something higher level,
> > similar to today's "set print elements", to apply.
> 
> That's a separate matter, which I raise in the topic starter. Yes, we want
> some safety net. As it stands, any IDE that automatically displays local
> variables is totally broken if pretty-printing is enabled.

The decision whether a std::string display should be limited to 100 or 
10000 characters or maybe whether it should be risked to show "all" is 
nothing that should be done on the gdb side, as all are valid choices
under certain circumstances.

So, please, don't make that kind of "high level" decision on the gdb side,
and also, please, generally take into account that other IDEs might
have other preferences than your IDE. 

At least from my point of view having a minimal(-ish) set of MI commands
providing fast and robust access to the data gdb can provide on the CLI is a 
lot more desirable than having a bigger part of _one_ IDE's logic hardwired
into gdb MI.

Andre'


  reply	other threads:[~2009-06-16  7:22 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-06-13 10:11 Vladimir Prus
2009-06-13 10:21 ` Vladimir Prus
2009-06-15 12:28   ` Phil Muldoon
2009-06-15 12:39     ` Vladimir Prus
2009-06-15 12:55       ` Daniel Jacobowitz
2009-06-15 13:25         ` Vladimir Prus
2009-06-16  7:22           ` André Pönitz [this message]
2009-06-15 20:01 ` Tom Tromey
2009-06-16  8:22   ` Vladimir Prus
2009-07-07 21:48     ` Tom Tromey
2009-07-09 17:20       ` Vladimir Prus
2009-07-09 19:14         ` Tom Tromey
2009-07-10  6:13           ` Vladimir Prus
2009-07-10 16:25             ` Tom Tromey
2009-07-10 16:40               ` Vladimir Prus
2009-07-10 16:48                 ` Tom Tromey
2009-07-10 18:46                   ` Vladimir Prus
2009-07-10 18:52                     ` Tom Tromey

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=200906160922.33025.andre.poenitz@nokia.com \
    --to=andre.poenitz@nokia.com \
    --cc=gdb@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