exception safety validation

François Dumont frs.dumont@gmail.com
Mon Nov 5 21:04:00 GMT 2012


I apply the attached patch.

2012-10-05  François Dumont  <fdumont@gcc.gnu.org>

     * include/ext/throw_allocator.h (__throw_value_base): Add move
     semantic, not throwing.
     (__throw_value_limit): Likewise.
     (__throw_value_random): Likewise.
     * testsuite/util/exception/safety.h: Add validation of C++11
     methods emplace/emplace_front/emplace_back/emplace_hint.
     * testsuite/util/testsuite_container_traits.h: Signal emplace
     support on deque, forward_list, list and vector.
     * testsuite/23_containers/deque/requirements/exception/
     propagation_consistent.cc: Remove dg-do run fail.

However I would still be interested in the original questions:
- why are the try{}catch(const __gnu_cxx::forced_error&) { throw; } for ?
- does the Standard says that move constructor shall not throw ?

François


On 11/04/2012 05:04 PM, Jonathan Wakely wrote:
> Ooh, I almost forgot, please remember to update the copyright years in
> the changed files.  For trunk you can change them to ranges like
> 2005-2012
>
> On 4 November 2012 16:01, Jonathan Wakely <jwakely.gcc@gmail.com> wrote:
>> On 3 November 2012 19:05, Paolo Carlini wrote:
>>> On 11/03/2012 03:43 PM, François Dumont wrote:
>>>> Note that I run exception tests to validate it and the recently introduced
>>>> 23_containers/forward_list/allocator/noexcept.cc test doesn't work in debug
>>>> mode. I think it needs a dg-require-normal-node attribute.
>>> ... if you reach an agreement about the right thing to do concerning this
>>> failure, I think the patch could otherwise go in.
>> Yes, the patch looks good, please commit it and  I'll look into the
>> forward_list failure, since my changes caused it.
>>
>> Thanks.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: exception_safety.patch
Type: text/x-patch
Size: 16555 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/libstdc++/attachments/20121105/bcfef7ce/attachment.bin>


More information about the Libstdc++ mailing list