Here, the copied list of contracts was getting garbage collected between
compilation of the .pre and .post functions. Instead of copying the list,
let's remap the conditions when we are ready to emit them.
gcc/cp/ChangeLog:
* contracts.cc (emit_contract_statement): Just add_stmt.
(emit_contract_attr): Renamed from above.
(emit_contract_conditions, emit_assertion): Adjust.
(remap_and_emit_conditions): New.
(finish_function_contracts): Use it.
gcc/testsuite/ChangeLog:
* g++.dg/contracts/contracts-deduced1.C: Use aggressive GC.