diff options
author | Martin Liska <mliska@suse.cz> | 2020-11-30 13:07:27 +0100 |
---|---|---|
committer | Martin Liska <mliska@suse.cz> | 2020-12-01 11:25:34 +0100 |
commit | cbc4ae2b263bced781a2d2d0cf0085d262040db6 (patch) | |
tree | 7867a3695bcda6042e12cdb991012620c173cce2 /gcc/symtab.c | |
parent | 69157fe75823fc34f1e3265345f2d2b99cd8d380 (diff) | |
download | gcc-cbc4ae2b263bced781a2d2d0cf0085d262040db6.zip gcc-cbc4ae2b263bced781a2d2d0cf0085d262040db6.tar.gz gcc-cbc4ae2b263bced781a2d2d0cf0085d262040db6.tar.bz2 |
IPA: drop implicit_section again
As mentioned in the PR, since 4656461585bfd0b9 implicit_section
was not set to false when set_section was called with the argument
equal to NULL.
gcc/ChangeLog:
PR ipa/98057
* symtab.c (symtab_node::set_section_for_node): Drop
implicit_section if x_section is NULL.
gcc/testsuite/ChangeLog:
PR ipa/98057
* g++.dg/ipa/pr98057.C: New test.
Diffstat (limited to 'gcc/symtab.c')
-rw-r--r-- | gcc/symtab.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/gcc/symtab.c b/gcc/symtab.c index fd7d553..6ceec55 100644 --- a/gcc/symtab.c +++ b/gcc/symtab.c @@ -1683,7 +1683,10 @@ symtab_node::set_section_for_node (const symtab_node &other) if (other.x_section) x_section = retain_section_hash_entry (other.x_section); else - x_section = NULL; + { + x_section = NULL; + implicit_section = false; + } } /* Workers for set_section. */ |