Remove possible trailing padding from aligned_storage. Patch from Yiran Wang

llvm-svn: 248309
This commit is contained in:
Eric Fiselier 2015-09-22 18:37:03 +00:00
parent 01205f79a4
commit 56465abe13
1 changed files with 2 additions and 2 deletions

View File

@ -1190,7 +1190,7 @@ struct _LIBCPP_TYPE_VIS_ONLY aligned_storage
union type
{
_Aligner __align;
unsigned char __data[_Len];
unsigned char __data[(_Len + _Align - 1)/_Align * _Align];
};
};
@ -1205,7 +1205,7 @@ struct _LIBCPP_TYPE_VIS_ONLY aligned_storage<_Len, n>\
{\
struct _ALIGNAS(n) type\
{\
unsigned char __lx[_Len];\
unsigned char __lx[(_Len + n - 1)/n * n];\
};\
}