Fix initialization of array<const T, 0> with GCC.
authorEric Fiselier <eric@efcs.ca>
Sun, 4 Feb 2018 08:02:35 +0000 (08:02 +0000)
committerEric Fiselier <eric@efcs.ca>
Sun, 4 Feb 2018 08:02:35 +0000 (08:02 +0000)
commitc6b3c7bb635352c7d228140ed0816befe2096944
tree6ab5dc83442cf71278069b405330b5ac634e5845
parent4f0c85310d880752684621d4afd2eea7f397bf99
Fix initialization of array<const T, 0> with GCC.

Previously, when handling zero-sized array of const objects we
used a const version of aligned_storage_t, which is not an array type.
However, GCC complains about initialization of the form: array<const T, 0> arr = {};

This patch fixes that bug by making the dummy object used to represent
the zero-sized array an array itself. This avoids GCC's complaints
about the uninitialized const member.

llvm-svn: 324194
libcxx/include/array