r280004 - in /branches/c++-coroutines: ChangeLo...

iains@gcc.gnu.org iains@gcc.gnu.org
Wed Jan 8 14:14:00 GMT 2020


Author: iains
Date: Wed Jan  8 14:14:31 2020
New Revision: 280004

URL: https://gcc.gnu.org/viewcvs?rev=280004&root=gcc&view=rev
Log:
c++-coroutines - Add promise overloads of new and delete.

[dcl.fct.def.coroutine] para 9 requires that we allow overloaded
operators new and delete in the coroutine promise type to be considered
before the global operators.

2020-01-08  Iain Sandoe  <iain@sandoe.co.uk>

	gcc/cp/
	* coroutines.cc (build_actor_fn): Handle use of overloaded
	operator delete.
	(morph_fn_to_coro): Handle use of overloaded operator new.

	gcc/testsuite/
	* g++.dg/coroutines/torture/gro_on_alloc_fail_0.C: Rename...
	* g++.dg/coroutines/torture/alloc-00-gro-on-alloc-fail.C: ... to this.
	* g++.dg/coroutines/torture/alloc-01-overload-newdel.C: New test.


Added:
    branches/c++-coroutines/gcc/testsuite/g++.dg/coroutines/torture/alloc-00-gro-on-alloc-fail.C
    branches/c++-coroutines/gcc/testsuite/g++.dg/coroutines/torture/alloc-01-overload-newdel.C
Removed:
    branches/c++-coroutines/gcc/testsuite/g++.dg/coroutines/torture/gro_on_alloc_fail_0.C
Modified:
    branches/c++-coroutines/ChangeLog.coroutines
    branches/c++-coroutines/gcc/cp/coroutines.cc



More information about the Gcc-cvs mailing list