Skip to content
  • Eric Fiselier's avatar
    c6b3c7bb
    Fix initialization of array<const T, 0> with GCC. · c6b3c7bb
    Eric Fiselier authored
    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
    c6b3c7bb
    Fix initialization of array<const T, 0> with GCC.
    Eric Fiselier authored
    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
Loading