This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: C++ vs. AIX -ansi
- To: Mark Mitchell <mark at codesourcery dot com>
- Subject: Re: C++ vs. AIX -ansi
- From: Nathan Sidwell <nathan at codesourcery dot com>
- Date: Tue, 06 Feb 2001 09:41:15 +0000
- CC: David Edelsohn <dje at watson dot ibm dot com>, gcc at gcc dot gnu dot org, libstdc++ at gcc dot gnu dot org
- Organization: Codesourcery LLC
- References: <20010205222751F.mitchell@codesourcery.com>
Mark Mitchell wrote:
>
> On AIX, `g++ -ansi' doesn't work very well depending on the order in
> which you #include things.
>
> Consider:
>
> #include <stdio.h>
> #include <fstream.h>
>
> This issues tons of errors.
FWIW the same problem existed on gnu/linux back in december see
http://gcc.gnu.org/ml/gcc-patches/2000-12/msg00449.html. I don't
know if it's fixed, as I've neglected to follow it up.
As David says, I think the relevant #defines must be provided
on the preprocessor command line -- or some fixincludes configurey
is needed.
> Me, I can live with `g++ -ansi' being broken. :-)
I can't :-( -- especially as I prefer g++ -ansi -pedantic
nathan
--
Dr Nathan Sidwell :: http://www.codesourcery.com :: CodeSourcery LLC
'But that's a lie.' - 'Yes it is. What's your point?'
nathan@codesourcery.com : http://www.cs.bris.ac.uk/~nathan/ : nathan@acm.org