https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92058
Bug ID: 92058
Summary: constinit disregards non-constexpr constructor
Product: gcc
Version: 10.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: mpolacek at gcc dot gnu.org
Target Milestone: ---
struct B {
B() {}
};
struct A {
constexpr static inline B b2{};
constinit static inline B b1{};
};
int main() {
A a;
}
Here b2 fails but b1 succeeds.
