c++: ICE with header-units [PR 99071]
authorNathan Sidwell <nathan@acm.org>
Wed, 17 Feb 2021 13:28:09 +0000 (05:28 -0800)
committerNathan Sidwell <nathan@acm.org>
Wed, 17 Feb 2021 13:41:37 +0000 (05:41 -0800)
commitd46c7e2c546b26d036856cf570694b832d3b1f54
tree9dd6d1ef2e769259684badf235fd4e2ec7cf8760
parent06505e701dcfdb1b9855601d6cf0aa1caea62975
c++: ICE with header-units [PR 99071]

This ICE was caused by dereferencing the wrong pointer and not finding the
expected thing there.  Pointers are like that.

PR c++/99071
gcc/cp/
* name-lookup.c (maybe_record_mergeable_decl): Deref the correct
pointer.
gcc/testsuite/
* g++.dg/modules/pr99071_a.H: New.
* g++.dg/modules/pr99071_b.H: New.
gcc/cp/name-lookup.c
gcc/testsuite/g++.dg/modules/pr99071_a.H [new file with mode: 0644]
gcc/testsuite/g++.dg/modules/pr99071_b.H [new file with mode: 0644]