public inbox for gcc-prs@sourceware.org help / color / mirror / Atom feed
From: ms@siroyan.com To: gcc-gnats@gcc.gnu.org Subject: c/7070: internal error with -Wunknown-pragmas && empty #pragma Date: Tue, 18 Jun 2002 10:46:00 -0000 [thread overview] Message-ID: <20020618164945.2886.qmail@sources.redhat.com> (raw) >Number: 7070 >Category: c >Synopsis: internal error with -Wunknown-pragmas && empty #pragma >Confidential: no >Severity: non-critical >Priority: medium >Responsible: unassigned >State: open >Class: rejects-legal >Submitter-Id: net >Arrival-Date: Tue Jun 18 09:56:02 PDT 2002 >Closed-Date: >Last-Modified: >Originator: Marcus Shawcroft >Release: 3.1 >Organization: >Environment: redhat 7.1 i686 >Description: The -Wunknown-pragmas option doesn;t like empty #pragma's. Try this on the attached file: gcc -Wall x.c Gives: internal error: x.c:1:8: unspellable token CPP_EOF >How-To-Repeat: >Fix: *** /project/vobtags/toolsdev/gcc/gcc/gcc/c-lex.c@@/main/Integration.5410/Integration.6110/ms_toolsdev/0 Tue Jun 18 17:27:17 2002 --- c-lex.c Tue Jun 18 17:27:54 2002 *************** *** 338,348 **** const cpp_token *s; s = cpp_get_token (pfile); - space = cpp_token_as_text (pfile, s); - s = cpp_get_token (pfile); if (s->type == CPP_NAME) ! name = cpp_token_as_text (pfile, s); ! lineno = SOURCE_LINE (map, line); if (name) warning ("ignoring #pragma %s %s", space, name); --- 338,350 ---- const cpp_token *s; s = cpp_get_token (pfile); if (s->type == CPP_NAME) ! { ! space = cpp_token_as_text (pfile, s); ! s = cpp_get_token (pfile); ! if (s->type == CPP_NAME) ! name = cpp_token_as_text (pfile, s); ! } lineno = SOURCE_LINE (map, line); if (name) warning ("ignoring #pragma %s %s", space, name); >Release-Note: >Audit-Trail: >Unformatted: ----gnatsweb-attachment---- Content-Type: application/octet-stream; name="x.c" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="x.c" I2luY2x1ZGUgPHN0ZGlvLmg+CgppbnQKbWFpbiAoaW50IGFyZ2MsIGNoYXIgKmFyZ3ZbXSkKewog IHByaW50ZiAoIkhlbGxvIFdvcmxkXG4iKTsKfQo=
next reply other threads:[~2002-06-18 16:56 UTC|newest] Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top 2002-06-18 10:46 ms [this message] 2002-06-19 4:23 neil
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=20020618164945.2886.qmail@sources.redhat.com \ --to=ms@siroyan.com \ --cc=gcc-gnats@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: linkBe 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).