public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
* c++/3652: default definition of _GNU_SOURCE breaks programs
@ 2001-07-11 14:36 enrico.scholz
  0 siblings, 0 replies; only message in thread
From: enrico.scholz @ 2001-07-11 14:36 UTC (permalink / raw)
  To: gcc-gnats

>Number:         3652
>Category:       c++
>Synopsis:       default definition of _GNU_SOURCE breaks programs
>Confidential:   no
>Severity:       serious
>Priority:       high
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Jul 11 14:36:00 PDT 2001
>Closed-Date:
>Last-Modified:
>Originator:     Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de>
>Release:        unknown-1.0
>Organization:
>Environment:
Host type: i386-redhat-linux-gnu
System: Linux kosh.ultra.csn.tu-chemnitz.de 2.4.6 #2 Mit Jul 4 08:30:43 CEST 2001 i686 unknown
Architecture: i686
>Description:
The current practice of g++3 to define _GNU_SOURCE has (propably) unwanted sideeffects making standard-conforming programs not working anymore.

E.g. _GNU_SOURCE leads to definition of _BSD_SOURCE which wastes the (global) namespace with macros having commonly used names (e.g. major, minor).

I have read issue #2082, but think that features should be enabled more selectively...
>How-To-Repeat:
Try to compile 
----------
#define _POSIX_SOURCE

#include <sys/types.h>

void major() {}
----------

with g++3 and g++2.
>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2001-07-11 14:36 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-07-11 14:36 c++/3652: default definition of _GNU_SOURCE breaks programs enrico.scholz

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