This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
Re: list::_M_check_equal_allocators throws
- From: François Dumont <frs dot dumont at gmail dot com>
- To: libstdc++ at gcc dot gnu dot org
- Date: Wed, 18 Sep 2013 21:26:16 +0200
- Subject: Re: list::_M_check_equal_allocators throws
- Authentication-results: sourceware.org; auth=none
- References: <alpine dot DEB dot 2 dot 10 dot 1309171540430 dot 11436 at stedding dot saclay dot inria dot fr> <CAH6eHdQRcLnkjPd8+rgZfbOFzbYwexy6VfYNXXfMEF5j1o+eYA at mail dot gmail dot com> <alpine dot DEB dot 2 dot 10 dot 1309171725420 dot 11436 at stedding dot saclay dot inria dot fr> <CAH6eHdRKo6X9sB5BY_j3vafC0_Uhuf5CEfpB1b1f+yAkDxiFHQ at mail dot gmail dot com>
On 09/17/2013 05:52 PM, Jonathan Wakely wrote:
I support adding noexcept specifications to places that shouldn't
throw, even if that prevents us using exceptions to identify undefined
behaviour, like this case. Others might disagree though, and prefer
having an exception thrown, so I'm interested to hear what other
people think.
In one of my TODOs for debug mode was the possibility for users to
request exceptions instead of an abortion on debug checks. In plugin
oriented application we have nowadays it is quite painful to have one of
the plugin to collapse the whole application because of some internal
issue while it could be simply unloaded. I know that we can't always
provide strong exception safety guaranty but I still think it worth the
effort.
But that would be for debug that might not have the same noecept
specification as the normal mode.
Maybe this choice between abortion or exception could be a user
decision through a configuration option. And not necessarily limited to
the debug mode.
François