[Bug c++/92947] New: Parenthesized aggregate initialization doesn't work with the library types it's supposed to work with
ville.voutilainen at gmail dot com
gcc-bugzilla@gcc.gnu.org
Sun Dec 15 20:21:00 GMT 2019
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92947
Bug ID: 92947
Summary: Parenthesized aggregate initialization doesn't work
with the library types it's supposed to work with
Product: gcc
Version: 10.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: ville.voutilainen at gmail dot com
Target Milestone: ---
struct aggressive_aggregate
{
int a;
int b;
};
int main()
{
static_assert(__is_constructible(aggressive_aggregate, int, int)); // fails
decltype(aggressive_aggregate(1,2)) foo; // ill-formed
bool b = noexcept(aggressive_aggregate(1,2)); // ill-formed
}
All of those things should work. The __is_constructible should be true,
and the decltype and noexcept should be well-formed.
More information about the Gcc-bugs
mailing list