This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ 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]

Re: Problems with PR 21210


On Tue, May 31, 2005 at 10:51:48PM -0700, Mark Mitchell wrote:
> Nathan (Jasper) Myers wrote:
> >On Tue, May 31, 2005 at 08:09:37PM -0700, Mark Mitchell wrote:
> >>Nathan (Jasper) Myers wrote:
> 
> >>Under this interpretation, would you have to #include <complex> before 
> >>you got to use _Complex?  (That's not true in C99.)
> > 
> >Of course not.
> 
> Well, I asked, because you have to #include <typeinfo> before you can 
> use std::type_info, which is rather more built-in than std::complex in 
> most compilers.

C++ programs can't mention std::complex without the header, and making 
_Complex a keyword need not change that.  Of course no C99 program can
mention std::complex, header or no.

> >This also depends on somebody not myself doing a not-insubstantial
> >amount of core compiler work to make it happen; and somebody else
> >jimmying the libstdc++ headers to match, presumably a lesser task.
> 
> I agree that this could be made to work, by essentially hard-wiring 
> std::complex/_Complex into the compiler, rather than defining it in
> the  library.
> 
> That would be a considerably more radical change, though; historically, 
> G++ has indeed treated the types as separate.

... albeit with results that are extremely unlikely to be compatible 
with the eventual standard.

Nathan Myers
ncm@codesourcery.com


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