Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Vladimir Prus <ghost@cs.msu.su>
To: Nick Roberts <nickrob@snap.net.nz>, gdb-patches@sources.redhat.com
Subject: Re: MI failures related to string printing
Date: Tue, 16 Jan 2007 02:08:00 -0000	[thread overview]
Message-ID: <E1H6dkH-0005Wy-Lu@zigzag.lvk.cs.msu.su> (raw)
In-Reply-To: <17831.31430.442855.801431@kahikatea.snap.net.nz>

Nick Roberts wrote:

>  > I think the whole idea of doing string comparisons for C (or C++)
>  > "char *" pointers is flawed.  There is no guarantee that a "char *"
>  > actually points to a null-terminated as the test shows.  You should
>  > not treat "char *" any different from other pointers like "int *", at
>  > least not by default.  You could implement a way for the user to
>  > specify that a "char *" is actually a pointer to a string instead of a
>  > single character.  But otherwise I think the string comparison should
>  > only do for languages that have a genuine string type, such as Pascal.
> 
> It's unfortunate you didn't express this opinion earlier.  There are no
> gauarantees but generally if you are watching a "char *" type it points to
> something useful, or you learn something if it doesn't.  Without string
> comparison you can't `watch' the contents of a string change.  I think
> it's better to focus on such practical issues than pathological cases in
> the testsuite.

Is there any chance you'll robustify the testsuite?

Thanks,
Volodya
 



       reply	other threads:[~2007-01-16  2:08 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <200701121351.29310.vladimir@codesourcery.com>
     [not found] ` <17831.31430.442855.801431@kahikatea.snap.net.nz>
2007-01-16  2:08   ` Vladimir Prus [this message]
2007-01-16  5:50     ` Nick Roberts
2007-01-16  6:42       ` Vladimir Prus
2007-01-16 20:44         ` Nick Roberts
2007-01-16 23:06           ` Vladimir Prus
2007-01-17  0:59             ` Nick Roberts
2007-01-17  6:01               ` Daniel Jacobowitz
2007-01-17  8:12                 ` Nick Roberts
2007-01-16 21:23       ` Mark Kettenis
2007-01-16 22:16         ` Nick Roberts
2007-01-17  6:06           ` Daniel Jacobowitz
2007-01-17 21:44             ` Mark Kettenis
2007-01-17 22:19               ` Daniel Jacobowitz

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=E1H6dkH-0005Wy-Lu@zigzag.lvk.cs.msu.su \
    --to=ghost@cs.msu.su \
    --cc=gdb-patches@sources.redhat.com \
    --cc=nickrob@snap.net.nz \
    /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