c++: Fix erroneous parm comparison logic [PR 98372]
authorNathan Sidwell <nathan@acm.org>
Thu, 14 Jan 2021 13:15:33 +0000 (05:15 -0800)
committerNathan Sidwell <nathan@acm.org>
Thu, 14 Jan 2021 13:31:07 +0000 (05:31 -0800)
commitd61d2a5f3ce9238bad7cbd7733d90c6ec7ae5fbc
tree46002f9934d03b658a4c3ab577d774ad73a6c0f3
parent08a4adcf2b6ded2fea97195c715757df61a23395
c++: Fix erroneous parm comparison logic [PR 98372]

I flubbed an application of De Morgan's law.  Let's just express the
logic directly and let the compiler figure it out.  This bug made it
look like pr52830 was fixed, but it is not.

PR c++/98372
gcc/cp/
* tree.c (cp_tree_equal): Correct map_context logic.
gcc/testsuite/
* g++.dg/cpp0x/constexpr-52830.C: Restore dg-ice
* g++.dg/template/pr98372.C: New.
gcc/cp/tree.c
gcc/testsuite/g++.dg/cpp0x/constexpr-52830.C
gcc/testsuite/g++.dg/template/pr98372.C [new file with mode: 0644]