public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jens Schweikhardt <schweikh@noc.dfn.de>
To: eggert@twinsun.com (Paul Eggert)
Cc: schweikh@diamant.noc.dfn.de, gcc2@cygnus.com, egcs@cygnus.com
Subject: Re: #line directive bug
Date: Tue, 24 Feb 1998 03:09:00 -0000	[thread overview]
Message-ID: <199802241108.MAA25719@obsidian.noc.dfn.de> (raw)
In-Reply-To: <199802241036.CAA26361@shade.twinsun.com>

Paul,

#    From: schweikh@diamant.noc.dfn.de (Jens Schweikhardt)
#    Date: 23 Feb 1998 10:08:57 GMT
#    Message-ID: <6crhrp$71$2@stuttgart.shuttle.de>
# 
#    #line 42 "foo\0bar"
# 
# Thanks for the bug report.  That "\0" causes cpp to expand __FILE__
# incorrectly, which means GCC silently generates incorrect code.
# I enclose a patch below, relative to the latest cccp.c snapshot.
 
Thanks for the quick response. I'm always impressed when I get
fixes for my bug reports the next day. The FreeBSD folks are
great as well :-)

# This patch fixes only the preprocessor.  Even with the patch, cc1 still
# outputs just "foo" for the file name in diagnostics; it should output
# "foo" followed by a NUL byte followed by "bar".  This is a bug, but
# it's a pain to fix and it's lower priority since it merely affects
# diagnostics and debugging info.  I wouldn't be surprised if most back
# ends can't handle NUL bytes in file names, as POSIX doesn't allow
# NULs in file names, so it might be best just to leave cc1 alone.

Well, I think I could live with that. Gcc was not the only compiler I
had trouble with. The Solaris SparcWorks compiler also has (another)
problem with line directives and IRIX c89 has yet another. Trying to
get someone from Sun to listen to me is a tricky excercise :-(

Thanks again for a great compiler. Keep up the good work.
I'll read you in comp.std.c.

Regards,

-- 
Jens Schweikhardt  http://www.shuttle.de/schweikh/
SIGSIG -- signature too long (core dumped)

      reply	other threads:[~1998-02-24  3:09 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <6crhrp$71$2@stuttgart.shuttle.de>
1998-02-24 11:46 ` Paul Eggert
1998-02-24  3:09   ` Jens Schweikhardt [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=199802241108.MAA25719@obsidian.noc.dfn.de \
    --to=schweikh@noc.dfn.de \
    --cc=egcs@cygnus.com \
    --cc=eggert@twinsun.com \
    --cc=gcc2@cygnus.com \
    --cc=schweikh@diamant.noc.dfn.de \
    /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).