public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
From: Mirsad Todorovac <mtodorov@alu.hr>
To: nobody@gcc.gnu.org
Cc: gcc-prs@gcc.gnu.org,
Subject: Re: c/2776: Wrong (misleading) error message in gcc 2.95.3
Date: Wed, 19 Feb 2003 18:56:00 -0000	[thread overview]
Message-ID: <20030219185601.25662.qmail@sources.redhat.com> (raw)

The following reply was made to PR c/2776; it has been noted by GNATS.

From: Mirsad Todorovac <mtodorov@alu.hr>
To: Wolfgang Bangerth <bangerth@ticam.utexas.edu>
Cc: gcc-bugs@gcc.gnu.org, <gcc-gnats@gcc.gnu.org>
Subject: Re: c/2776: Wrong (misleading) error message in gcc 2.95.3
Date: Wed, 19 Feb 2003 19:48:38 +0100 (CET)

 On Wed, 19 Feb 2003, Wolfgang Bangerth wrote:
 
 >
 > > I apologize if I was wasting your precious timewith this as it now seems
 > > not so important issue, but I wasted so much time resolving it that I
 > > thought it was important to be resolved, or at least known issue.
 > >
 > > Thank you for your time. Mirsad
 >
 > No problem. This is just one of the cases where what you wanted would
 > require the compiler to second-guess what was your original intention.
 > Your example boiled down to
 >   char *p = hip hop step;
 > The problem was the missing quotes (which the compiler can't know, since
 > the three tokens came from the preprocessor, and there might be many
 > possible interpretations of what the orginal intent was:
 >   char *p = "hip hop step";
 >   char *p = hip+hop+step;     // hip=char*, hop,step=int
 >   char *p = hiphopstep;       // hiphopstep=char*
 > etc. There is just not something sensible the compiler can say here,
 > except for "parse error" or so.
 >
 > With respect to the fact that the error message was totally
 > incomprehensible: most experienced programmers know that if something is
 > _really_ incomprehensible, the look at the preprocessed sources. I'd say
 > this is for exactly the same kind of experience you just made :-(
 
 Thank you for this explanation, which makes things much clearer. I
 understand that AI is probably not a good thing to install in a compiler,
 since a compiler has to be small and reliable, hasn't it? :-))
 
 Be blessed,
 M.
 
 


             reply	other threads:[~2003-02-19 18:56 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-02-19 18:56 Mirsad Todorovac [this message]
  -- strict thread matches above, loose matches on Subject: below --
2003-02-19 17:06 Wolfgang Bangerth
2003-02-19 16:56 Mirsad Todorovac
2003-02-19 14:27 bangerth
2003-02-19 14:06 Steven Bosscher
2001-05-08 10:56 mtodorov

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=20030219185601.25662.qmail@sources.redhat.com \
    --to=mtodorov@alu.hr \
    --cc=gcc-prs@gcc.gnu.org \
    --cc=nobody@gcc.gnu.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).