This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

other/9244: NetBSD sys/cdefs.h needs a fixincludes hack


>Number:         9244
>Category:       other
>Synopsis:       NetBSD sys/cdefs.h needs a fixincludes hack
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu Jan 09 06:16:03 PST 2003
>Closed-Date:
>Last-Modified:
>Originator:     Richard Earnshaw
>Release:        unknown-1.0
>Organization:
>Environment:
any NetBSD target for any relase other than -current.  Any release of GCC with the new C++ parser.
>Description:
The new C++ parser rejects the (invalid) construct

  extern "C" {
    // decls
  };  // Bogus semicolon

But this is the way that __END_DECLS in sys/cdefs.h is defined on existing NetBSD installations.  (Current has now been fixed.)
>How-To-Repeat:
Try to build any C++ program that includes stdio.h with the new compiler on NetBSD
>Fix:
Add a fixincludes rule to fix this case up.  The file is sys/cdefs.h and the macro __END_DECLS is defined to '};' rather than just '}'

Note that the definition of __END_DECLS as an empty define must not be affected; this is needed for C.
>Release-Note:
>Audit-Trail:
>Unformatted:


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]