From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 26787 invoked by alias); 30 Apr 2010 14:42:25 -0000 Received: (qmail 26731 invoked by alias); 30 Apr 2010 14:42:11 -0000 Date: Fri, 30 Apr 2010 14:42:00 -0000 Message-ID: <20100430144211.26730.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug libstdc++/36231] ostream includes unistd.h outside namespace std, polluting In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "joseph at codesourcery dot com" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2010-04/txt/msg03358.txt.bz2 ------- Comment #10 from joseph at codesourcery dot com 2010-04-30 14:42 ------- Subject: Re: ostream includes unistd.h outside namespace std, polluting On Fri, 30 Apr 2010, igodard at pacbell dot net wrote: > namespace that has not been opened by "using". My report says that gcc violates > that standard, because it gratuitously dumps POSIX names into my global space. It does more than that - for C++ it defines _GNU_SOURCE and so causes many non-standard names to be defined as well. Fixing this requires cooperation from libc maintainers to provide implementation-namespace versions of whatever functions libstdc++ wishes to use from its headers that are not included in strict ISO C90+AMD1, and I doubt such cooperation will be forthcoming. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36231