Bug ID: 85385
           Summary: [8 Regression] Bogus "macro had not yet been defined"
                    message when macro used with wrong arg count
           Product: gcc
           Version: 8.0
            Status: UNCONFIRMED
          Keywords: diagnostic
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot
          Reporter: dmalcolm at gcc dot
  Target Milestone: ---

$ cat test.c
#define MACRO(X,Y)

void test ()

$ ./xg++ -B. -c test.c
test.c:5:11: error: macro "MACRO" requires 2 arguments, but only 1 given
test.c: In function ‘void test()’:
test.c:5:3: error: ‘MACRO’ was not declared in this scope
test.c:5:3: note: 
test.c:1: note: it was later defined here
 #define MACRO(X,Y)

We shouldn't emit the note "the macro ‘MACRO’ had not yet been defined" for
cases like these: the macro *had* been defined.

Reply via email to