* [Bug c++/93413] Destructor definition not found during constant evaluation
[not found] <bug-93413-4@http.gcc.gnu.org/bugzilla/>
@ 2021-04-24 2:39 ` ldalessandro at gmail dot com
2021-08-17 5:56 ` pinskia at gcc dot gnu.org
` (9 subsequent siblings)
10 siblings, 0 replies; 11+ messages in thread
From: ldalessandro at gmail dot com @ 2021-04-24 2:39 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93413
Luke Dalessandro <ldalessandro at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |ldalessandro at gmail dot com
--- Comment #2 from Luke Dalessandro <ldalessandro at gmail dot com> ---
I just ran into this today. The referenced "dup" seems to have been resolved
last June, but this is still failing. Also probably the same as
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99495.
Is there any chance someone could take a fresh look at this?
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/93413] Destructor definition not found during constant evaluation
[not found] <bug-93413-4@http.gcc.gnu.org/bugzilla/>
2021-04-24 2:39 ` [Bug c++/93413] Destructor definition not found during constant evaluation ldalessandro at gmail dot com
@ 2021-08-17 5:56 ` pinskia at gcc dot gnu.org
2021-08-17 5:57 ` pinskia at gcc dot gnu.org
` (8 subsequent siblings)
10 siblings, 0 replies; 11+ messages in thread
From: pinskia at gcc dot gnu.org @ 2021-08-17 5:56 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93413
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |pkeir at outlook dot com
--- Comment #3 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
*** Bug 96614 has been marked as a duplicate of this bug. ***
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/93413] Destructor definition not found during constant evaluation
[not found] <bug-93413-4@http.gcc.gnu.org/bugzilla/>
2021-04-24 2:39 ` [Bug c++/93413] Destructor definition not found during constant evaluation ldalessandro at gmail dot com
2021-08-17 5:56 ` pinskia at gcc dot gnu.org
@ 2021-08-17 5:57 ` pinskia at gcc dot gnu.org
2021-08-17 5:58 ` pinskia at gcc dot gnu.org
` (7 subsequent siblings)
10 siblings, 0 replies; 11+ messages in thread
From: pinskia at gcc dot gnu.org @ 2021-08-17 5:57 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93413
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |oleksandr.koval.dev at gmail dot c
| |om
--- Comment #4 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
*** Bug 99495 has been marked as a duplicate of this bug. ***
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/93413] Destructor definition not found during constant evaluation
[not found] <bug-93413-4@http.gcc.gnu.org/bugzilla/>
` (2 preceding siblings ...)
2021-08-17 5:57 ` pinskia at gcc dot gnu.org
@ 2021-08-17 5:58 ` pinskia at gcc dot gnu.org
2022-02-23 7:46 ` pinskia at gcc dot gnu.org
` (6 subsequent siblings)
10 siblings, 0 replies; 11+ messages in thread
From: pinskia at gcc dot gnu.org @ 2021-08-17 5:58 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93413
--- Comment #5 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
The problem is the default Destructor in the Derived for the other examples.
So this can be reduced to just:
struct Base
{
constexpr virtual ~Base() = default;
};
constexpr Base b;
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/93413] Destructor definition not found during constant evaluation
[not found] <bug-93413-4@http.gcc.gnu.org/bugzilla/>
` (3 preceding siblings ...)
2021-08-17 5:58 ` pinskia at gcc dot gnu.org
@ 2022-02-23 7:46 ` pinskia at gcc dot gnu.org
2022-07-13 22:44 ` pinskia at gcc dot gnu.org
` (5 subsequent siblings)
10 siblings, 0 replies; 11+ messages in thread
From: pinskia at gcc dot gnu.org @ 2022-02-23 7:46 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93413
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |lichray at gmail dot com
--- Comment #6 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
*** Bug 104653 has been marked as a duplicate of this bug. ***
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/93413] Destructor definition not found during constant evaluation
[not found] <bug-93413-4@http.gcc.gnu.org/bugzilla/>
` (4 preceding siblings ...)
2022-02-23 7:46 ` pinskia at gcc dot gnu.org
@ 2022-07-13 22:44 ` pinskia at gcc dot gnu.org
2022-07-13 22:45 ` pinskia at gcc dot gnu.org
` (4 subsequent siblings)
10 siblings, 0 replies; 11+ messages in thread
From: pinskia at gcc dot gnu.org @ 2022-07-13 22:44 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93413
--- Comment #7 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
*** Bug 106287 has been marked as a duplicate of this bug. ***
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/93413] Destructor definition not found during constant evaluation
[not found] <bug-93413-4@http.gcc.gnu.org/bugzilla/>
` (5 preceding siblings ...)
2022-07-13 22:44 ` pinskia at gcc dot gnu.org
@ 2022-07-13 22:45 ` pinskia at gcc dot gnu.org
2022-11-02 20:39 ` pinskia at gcc dot gnu.org
` (3 subsequent siblings)
10 siblings, 0 replies; 11+ messages in thread
From: pinskia at gcc dot gnu.org @ 2022-07-13 22:45 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93413
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |benni at stuerz dot xyz
--- Comment #8 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
*** Bug 105846 has been marked as a duplicate of this bug. ***
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/93413] Destructor definition not found during constant evaluation
[not found] <bug-93413-4@http.gcc.gnu.org/bugzilla/>
` (6 preceding siblings ...)
2022-07-13 22:45 ` pinskia at gcc dot gnu.org
@ 2022-11-02 20:39 ` pinskia at gcc dot gnu.org
2022-11-02 23:58 ` [Bug c++/93413] Defaulted constexpr Destructor not being " ppalka at gcc dot gnu.org
` (2 subsequent siblings)
10 siblings, 0 replies; 11+ messages in thread
From: pinskia at gcc dot gnu.org @ 2022-11-02 20:39 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93413
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |kacper.slominski72 at gmail dot co
| |m
--- Comment #9 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
*** Bug 107512 has been marked as a duplicate of this bug. ***
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/93413] Defaulted constexpr Destructor not being found during constant evaluation
[not found] <bug-93413-4@http.gcc.gnu.org/bugzilla/>
` (7 preceding siblings ...)
2022-11-02 20:39 ` pinskia at gcc dot gnu.org
@ 2022-11-02 23:58 ` ppalka at gcc dot gnu.org
2022-11-03 18:56 ` cvs-commit at gcc dot gnu.org
2022-11-03 19:11 ` ppalka at gcc dot gnu.org
10 siblings, 0 replies; 11+ messages in thread
From: ppalka at gcc dot gnu.org @ 2022-11-02 23:58 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93413
Patrick Palka <ppalka at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Assignee|unassigned at gcc dot gnu.org |ppalka at gcc dot gnu.org
Status|NEW |ASSIGNED
CC| |ppalka at gcc dot gnu.org
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/93413] Defaulted constexpr Destructor not being found during constant evaluation
[not found] <bug-93413-4@http.gcc.gnu.org/bugzilla/>
` (8 preceding siblings ...)
2022-11-02 23:58 ` [Bug c++/93413] Defaulted constexpr Destructor not being " ppalka at gcc dot gnu.org
@ 2022-11-03 18:56 ` cvs-commit at gcc dot gnu.org
2022-11-03 19:11 ` ppalka at gcc dot gnu.org
10 siblings, 0 replies; 11+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-11-03 18:56 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93413
--- Comment #10 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Patrick Palka <ppalka@gcc.gnu.org>:
https://gcc.gnu.org/g:c0b38e9fec71dc4cc5e99b1f0cb159c15a8da9ba
commit r13-3638-gc0b38e9fec71dc4cc5e99b1f0cb159c15a8da9ba
Author: Patrick Palka <ppalka@redhat.com>
Date: Thu Nov 3 14:55:35 2022 -0400
c++: constexpr error with defaulted virtual dtor [PR93413]
We're rejecting the below testcase with
error: 'virtual constexpr Base::~Base()' used before its definition
error: 'virtual constexpr Derived::~Derived()' used before its definition
due to special handling in mark_used added by r181272 to defer synthesis
of virtual destructors until EOF (where we can set their linkage), which
in turn makes them effectively unusable during constexpr evaluation.
Fortunately it seems this special handling is unnecessary ever since
r208030 enabled us to tentatively set linkage of all defaulted virtual
destructors, including templated ones. So this patch gets rid of this
special handling.
PR c++/93413
gcc/cp/ChangeLog:
* decl2.cc (mark_used): Don't defer synthesis of virtual
functions.
gcc/testsuite/ChangeLog:
* g++.dg/cpp2a/constexpr-virtual21.C: New test.
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/93413] Defaulted constexpr Destructor not being found during constant evaluation
[not found] <bug-93413-4@http.gcc.gnu.org/bugzilla/>
` (9 preceding siblings ...)
2022-11-03 18:56 ` cvs-commit at gcc dot gnu.org
@ 2022-11-03 19:11 ` ppalka at gcc dot gnu.org
10 siblings, 0 replies; 11+ messages in thread
From: ppalka at gcc dot gnu.org @ 2022-11-03 19:11 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93413
Patrick Palka <ppalka at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Resolution|--- |FIXED
Status|ASSIGNED |RESOLVED
Target Milestone|--- |13.0
--- Comment #11 from Patrick Palka <ppalka at gcc dot gnu.org> ---
Fixed for GCC 13. The fix is probably unsuitable for backporting, and there
are workarounds anyway -- one workaround is to turn the problematic class into
a class template with an explicitly defaulted dtor, e.g. for the original
testcase do:
struct Base {
constexpr virtual ~Base(){}
};
template<class=void>
struct Derived: Base {
~Derived() = default;
};
constexpr Derived<> d;
^ permalink raw reply [flat|nested] 11+ messages in thread