diff options
author | Nathaniel Shead <nathanieloshead@gmail.com> | 2024-10-31 20:05:16 +1100 |
---|---|---|
committer | Nathaniel Shead <nathanieloshead@gmail.com> | 2024-11-02 22:16:30 +1100 |
commit | 815e48e3d42231b675bae1dec5fa26890f048ef1 (patch) | |
tree | 01e458c5a34330f09271ef67f14410ac0266237d /gcc/testsuite/g++.dg/other/i386-2.C | |
parent | 4a99443c5dd9a235022652ba0fb143c6370ea99d (diff) | |
download | gcc-master.zip gcc-master.tar.gz gcc-master.tar.bz2 |
In some cases, when we go to import a partial specialisation there might
already be an incomplete implicit instantiation in the specialisation
table. This causes ICEs described in the linked PR as we now have two
separate matching specialisations for this same arguments with different
TYPE_CANONICAL.
We already support multiple specialisations with the same args however,
as they may be differently constrained. So we can solve this by simply
ensuring that the TYPE_CANONICAL of the new partial specialisation
matches the existing specialisation.
PR c++/113814
gcc/cp/ChangeLog:
* pt.cc (add_mergeable_specialization): Propagate
TYPE_CANONICAL.
gcc/testsuite/ChangeLog:
* g++.dg/modules/partial-6.h: New test.
* g++.dg/modules/partial-6_a.H: New test.
* g++.dg/modules/partial-6_b.H: New test.
* g++.dg/modules/partial-6_c.C: New test.
Signed-off-by: Nathaniel Shead <nathanieloshead@gmail.com>
Co-authored-by: Jason Merrill <jason@redhat.com>
Diffstat (limited to 'gcc/testsuite/g++.dg/other/i386-2.C')
0 files changed, 0 insertions, 0 deletions