public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/106287] New: Implicit virtual destructor needs to be explicitly defaulted for constant evaluation
@ 2022-07-13 22:32 johelegp at gmail dot com
2022-07-13 22:44 ` [Bug c++/106287] " pinskia at gcc dot gnu.org
0 siblings, 1 reply; 2+ messages in thread
From: johelegp at gmail dot com @ 2022-07-13 22:32 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106287
Bug ID: 106287
Summary: Implicit virtual destructor needs to be explicitly
defaulted for constant evaluation
Product: gcc
Version: 13.0
Status: UNCONFIRMED
Keywords: rejects-valid
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: johelegp at gmail dot com
CC: johelegp at gmail dot com
Target Milestone: ---
See https://godbolt.org/z/4WaevWoEs.
```C++
template<class T> struct A : T {
constexpr A(T v) : T{v} { }
// ~A() = default; // Fixes GCC.
};
struct B {
virtual ~B() = default;
};
inline constexpr auto x = A{B{}};
```
```
<source>:10:32: error: 'virtual constexpr A<B>::~A()' used before its
definition
10 | inline constexpr auto x = A{B{}};
| ^
Compiler returned: 1
```
^ permalink raw reply [flat|nested] 2+ messages in thread
* [Bug c++/106287] Implicit virtual destructor needs to be explicitly defaulted for constant evaluation
2022-07-13 22:32 [Bug c++/106287] New: Implicit virtual destructor needs to be explicitly defaulted for constant evaluation johelegp at gmail dot com
@ 2022-07-13 22:44 ` pinskia at gcc dot gnu.org
0 siblings, 0 replies; 2+ 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=106287
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Resolution|--- |DUPLICATE
Status|UNCONFIRMED |RESOLVED
--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Dup of bug 93413.
*** This bug has been marked as a duplicate of bug 93413 ***
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2022-07-13 22:44 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-13 22:32 [Bug c++/106287] New: Implicit virtual destructor needs to be explicitly defaulted for constant evaluation johelegp at gmail dot com
2022-07-13 22:44 ` [Bug c++/106287] " pinskia at gcc dot gnu.org
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).