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]

Re: new type (initializer) --- bug ???


Ruediger Schopper <schopper@hal15.usm.uni-muenchen.de> writes:

> When one gives an initializer to the new operator, it
> compiles with aggregate types, but not with built in ones.

First of all, I should tell you that this is not Standard C++; it is
an extension provided by g++, so you'd better not rely on that.  If
you compile with -ansi -pedantic, you'll get error messages for those
usages.  However, for simmetry, egcs should provide the extension for
all types or for none, so I added the attached testcase to the
testsuite.

-- 
Alexandre Oliva
mailto:oliva@dcc.unicamp.br mailto:oliva@gnu.org mailto:aoliva@acm.org
http://www.dcc.unicamp.br/~oliva
Universidade Estadual de Campinas, SP, Brasil

arrnew2.C


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