This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: RFA (tree.c): PATCH for c++/68782 (wrong TREE_CONSTANT flag on C++ CONSTRUCTOR)
- From: Jakub Jelinek <jakub at redhat dot com>
- To: Jason Merrill <jason at redhat dot com>
- Cc: gcc-patches List <gcc-patches at gcc dot gnu dot org>
- Date: Tue, 26 Jan 2016 21:51:28 +0100
- Subject: Re: RFA (tree.c): PATCH for c++/68782 (wrong TREE_CONSTANT flag on C++ CONSTRUCTOR)
- Authentication-results: sourceware.org; auth=none
- References: <56A7D4F4 dot 5020102 at redhat dot com> <20160126203213 dot GH3017 at tucnak dot redhat dot com> <56A7DB3A dot 9060704 at redhat dot com>
- Reply-to: Jakub Jelinek <jakub at redhat dot com>
On Tue, Jan 26, 2016 at 03:46:50PM -0500, Jason Merrill wrote:
> On 01/26/2016 03:32 PM, Jakub Jelinek wrote:
> >>>+ if (CHECKING_P)
> >>>+ verify_constructor_flags (t);
> >>>+ else
> >>>+ recompute_constructor_flags (t);
>
> >But I don't understand this. Either the flags are supposed to be already
> >correct here, then I'd expect to see
> > if (CHECKING_P)
> > verify_constructor_flags (t);
> >only, or they are not guaranteed to be correct, and then I'd expect
> >unconditional
> > recompute_constructor_flags (t).
> >
>
> They are supposed to be correct, so when --enable-checking, we check for
> that. The recompute is for better fault-tolerance in release compilers in
> case the patch doesn't catch everything.
Ah, ok. But please make sure to remove it after GCC 6 branches.
Jakub