This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [C++ Patch] PR 58102 aka DR 1405
- From: Jason Merrill <jason at redhat dot com>
- To: Paolo Carlini <paolo dot carlini at oracle dot com>, "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>
- Date: Tue, 02 Sep 2014 11:45:27 -0400
- Subject: Re: [C++ Patch] PR 58102 aka DR 1405
- Authentication-results: sourceware.org; auth=none
- References: <5404790A dot 8020402 at oracle dot com> <5405CFF4 dot 7060008 at redhat dot com> <5405D174 dot 1050509 at oracle dot com> <5405D402 dot 7020807 at redhat dot com> <5405DD3E dot 7030506 at oracle dot com>
On 09/02/2014 11:07 AM, Paolo Carlini wrote:
Anyway, what about the below? Certainly works for the tests which we
have got.
Hmm. This is definitely an improvement, as it allows a subset of
a non-volatile glvalue of literal type that refers to a non-volatile
object whose lifetime began within the evalution of e
But it doesn't cover all of that, and in any case we shouldn't need to
explicitly handle that just for types with mutable subobjects.
I think perhaps it would be better to remove that hunk as in your
initial patch and replace it with a check in constant_value_1 and an
explanation in non_const_var_error.
Jason