public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug preprocessor/60744] New: poor location and error recovery
@ 2014-04-03 12:22 manu at gcc dot gnu.org
  2021-08-02  3:32 ` [Bug preprocessor/60744] poor location and error recovery for unterminated argument list invoking macro pinskia at gcc dot gnu.org
  0 siblings, 1 reply; 2+ messages in thread
From: manu at gcc dot gnu.org @ 2014-04-03 12:22 UTC (permalink / raw)
  To: gcc-bugs

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="UTF-8", Size: 5609 bytes --]

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60744

            Bug ID: 60744
           Summary: poor location and error recovery
           Product: gcc
           Version: 4.9.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: preprocessor
          Assignee: unassigned at gcc dot gnu.org
          Reporter: manu at gcc dot gnu.org

#define DEBUG(X) X

void foo(void)
{
    DEBUG((
              0);
}

test.c: In function ‘foo’:
test.c:7:0: error: unterminated argument list invoking macro "DEBUG"
 }
 ^
test.c:5:5: error: ‘DEBUG’ undeclared (first use in this function)
     DEBUG((
     ^
test.c:5:5: note: each undeclared identifier is reported only once for each
function it appears in
test.c:5:5: error: expected ‘;’ at end of input
test.c:5:5: error: expected declaration or statement at end of input


Problems:

1. The first error does not point to the point where the macro was invoked,
which is the key location. Clang gets this right.

2. All the other errors are useless. This should be a fatal error, since it
will gobble the rest of the input and produce meaningless cascades of errors.
>From gcc-bugs-return-448188-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Thu Apr 03 12:23:10 2014
Return-Path: <gcc-bugs-return-448188-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 9848 invoked by alias); 3 Apr 2014 12:23:10 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 9818 invoked by uid 48); 3 Apr 2014 12:23:06 -0000
From: "manu at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug preprocessor/60744] poor location and error recovery
Date: Thu, 03 Apr 2014 12:23:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: preprocessor
X-Bugzilla-Version: 4.9.0
X-Bugzilla-Keywords: diagnostic
X-Bugzilla-Severity: normal
X-Bugzilla-Who: manu at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: keywords bug_status cf_reconfirmed_on everconfirmed
Message-ID: <bug-60744-4-iuFoIxiLem@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-60744-4@http.gcc.gnu.org/bugzilla/>
References: <bug-60744-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2014-04/txt/msg00208.txt.bz2
Content-length: 480

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60744

Manuel López-Ibáñez <manu at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |diagnostic
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2014-04-03
     Ever confirmed|0                           |1
>From gcc-bugs-return-448189-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Thu Apr 03 12:24:45 2014
Return-Path: <gcc-bugs-return-448189-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 11135 invoked by alias); 3 Apr 2014 12:24:45 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 11090 invoked by uid 48); 3 Apr 2014 12:24:42 -0000
From: "iains at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/59617] [vectorizer] ICE in vectorizable_mask_load_store with AVX-512F's gathers enabled.
Date: Thu, 03 Apr 2014 12:24:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: tree-optimization
X-Bugzilla-Version: 4.9.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: iains at gcc dot gnu.org
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-59617-4-Q1gyO8m9Ir@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-59617-4@http.gcc.gnu.org/bugzilla/>
References: <bug-59617-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 7bit
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2014-04/txt/msg00209.txt.bz2
Content-length: 275

http://gcc.gnu.org/bugzilla/show_bug.cgi?idY617

--- Comment #14 from Iain Sandoe <iains at gcc dot gnu.org> ---
(In reply to Dominique d'Humieres from comment #13)
> Another option would be to add -stdÉ9 for darwin.

I would suggest that this is the Right Thing to do.


^ permalink raw reply	[flat|nested] 2+ messages in thread

* [Bug preprocessor/60744] poor location and error recovery for unterminated argument list invoking macro
  2014-04-03 12:22 [Bug preprocessor/60744] New: poor location and error recovery manu at gcc dot gnu.org
@ 2021-08-02  3:32 ` pinskia at gcc dot gnu.org
  0 siblings, 0 replies; 2+ messages in thread
From: pinskia at gcc dot gnu.org @ 2021-08-02  3:32 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60744

--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
GCC's tokenizer does not eat the token for DEBUG and inserts it still.  maybe
eating it is the way to fix this.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-08-02  3:32 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-04-03 12:22 [Bug preprocessor/60744] New: poor location and error recovery manu at gcc dot gnu.org
2021-08-02  3:32 ` [Bug preprocessor/60744] poor location and error recovery for unterminated argument list invoking macro pinskia at gcc dot gnu.org

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).