This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] Fix PR 51198, DECL_INITIAL still contains stuff for FIELD_DECLs


Hi,
  With C++11's decl initialization for non static members, the
DECL_INITIAL for FIELD_DECLs contains stuff which we don't need to
keep around after the front-end is done.  This patch clears them in
the free_lang_data pass.

OK? Bootstrapped and tested on x86_64-linux-gnu with no regressions.

Thanks,
Andrew Pinski

ChangeLog:
* tree.c (free_lang_data_in_decl): Clear FIELD_DECL's DECL_INITIAL also.

testsuite/ChangeLog:
* g++.dg/torture/pr51198.C: New testcase.

Attachment: clearfielddeclinit.diff.txt
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]