This is the mail archive of the
mailing list for the GCC project.
Re: C++ PATCH for more checking of DECL_MUTABLE_P
- From: Jason Merrill <jason at redhat dot com>
- To: Marek Polacek <polacek at redhat dot com>, GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Tue, 13 Aug 2019 10:51:36 -0400
- Subject: Re: C++ PATCH for more checking of DECL_MUTABLE_P
- References: <20190810185730.GA14737@redhat.com>
On 8/10/19 2:57 PM, Marek Polacek wrote:
Some preparatory work before adding constinit. mutable is only appropriate for
FIELD_DECLs (when they're not static), but we've never made sure that we're not
setting DECL_MUTABLE_P on a different _DECL. I mean to use DECL_LANG_FLAG_0 in
a VAR_DECL for DECL_DECLARED_CONSTINIT_P.
Bootstrapped/regtested on x86_64-linux, ok for trunk?
2019-08-10 Marek Polacek <firstname.lastname@example.org>
* cp-tree.h (DECL_MUTABLE_P): Use FIELD_DECL_CHECK.