r279943 - in /trunk/gcc: cp/ChangeLog cp/conste...
jakub@gcc.gnu.org
jakub@gcc.gnu.org
Tue Jan 7 07:13:00 GMT 2020
Author: jakub
Date: Tue Jan 7 07:13:50 2020
New Revision: 279943
URL: https://gcc.gnu.org/viewcvs?rev=279943&root=gcc&view=rev
Log:
PR c++/91369
* constexpr.c (struct constexpr_global_ctx): Add heap_alloc_count
member, initialize it to zero in ctor.
(cxx_eval_call_expression): Bump heap_dealloc_count when deleting
a heap object. Don't cache calls to functions which allocate some
heap objects and don't deallocate them or deallocate some heap
objects they didn't allocate.
* g++.dg/cpp1y/constexpr-new.C: Expect an error explaining why
static_assert failed for C++2a.
* g++.dg/cpp2a/constexpr-new9.C: New test.
Added:
trunk/gcc/testsuite/g++.dg/cpp2a/constexpr-new9.C
Modified:
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/constexpr.c
trunk/gcc/testsuite/ChangeLog
trunk/gcc/testsuite/g++.dg/cpp1y/constexpr-new.C
More information about the Gcc-cvs
mailing list