This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
Re: std::rethrow_exception is broken
- From: Jonathan Wakely <jwakely at redhat dot com>
- To: François Dumont <frs dot dumont at gmail dot com>
- Cc: libstdc++ at gcc dot gnu dot org
- Date: Thu, 27 Mar 2014 21:58:05 +0000
- Subject: Re: std::rethrow_exception is broken
- Authentication-results: sourceware.org; auth=none
- References: <CAH6eHdQG3ZqSqckxwQG=6H8qhs9q0H5L7JXxVFZMtMVkdqmM+g at mail dot gmail dot com> <20140325172551 dot GD8266 at redhat dot com> <53349689 dot 1010408 at gmail dot com>
On 27/03/14 22:22 +0100, François Dumont wrote:
Shouldn't static assertion messages say that layout is incorrect ? It
is strange to have compilation error with a message saying that it is
correct, isn't it ?
The assertion is that the layout is correct, and if that's not true
the message says "static assertion failed: layout is correct".
The error message would say that the assertion "layout is correct"
failed, where that string is an English description of the condition
being asserted.
If you compare it to a traditional assert() then you get "assertion
'xxx' failed" where xxx is the condition being tested.
But as far as I know the C++ community hasn't decided yet whether it's
better to use the string to describe the condition that failed, or
give a meaningful diagnostic.
I could reword it to avoid the word correct, I suppose.