On Tue, May 29, 2012 at 11:00 AM, Florian Weimer <fwei...@redhat.com> wrote: > This patch flags operator new on variably modified types as an error. > If this is acceptable, this will simplify the implementation of the > C++11 requirement to throw std::bad_array_new_length instead of > allocating a memory region which is too short. > > Okay for trunk? Or should I guard this with -fpermissive?
I must say that ideally this should go in. However, this having been accepted in previous releases, I think people would like one release of deprecation. So my suggestion is: -- make it an error unless -fpermissive. -- if -fpermissive, make it unconditionally deprecated. -- schedule for entire removal in 4.9. > > 2012-05-29 Florian Weimer <fwei...@redhat.com> > > * init.c (build_new): Reject variably modified types. > > > 2012-05-29 Florian Weimer <fwei...@redhat.com> > > * g++.dg/init/new33.C: New. > > -- > Florian Weimer / Red Hat Product Security Team