http://llvm.org/bugs/show_bug.cgi?id=19879
Bug ID: 19879
Summary: aggregate initialization uses value initialization
rather than initialization from {} for subobjects with
no initializer
Product: clang
Version: unspecified
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P
Component: C++11
Assignee: [email protected]
Reporter: [email protected]
CC: [email protected], [email protected]
Classification: Unclassified
Clang rejects this valid code:
#include <initializer_list>
struct S { S(std::initializer_list<int>); } s[1] = {};
... because we use the pre-DR1070/DR990 rule for aggregate initialization. We
should initialize s[0] from {}, which works, rather than trying to
value-initialize it (which does not work).
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs