mirror of
https://github.com/llvm/llvm-project.git
synced 2025-05-02 06:36:08 +00:00
[demangler] Fix a MSVC alignment warning.
This should fix llvm.org/PR37944 llvm-svn: 336157
This commit is contained in:
parent
aa60b3fd87
commit
d26ace3955
@ -19,6 +19,7 @@
|
||||
#include <algorithm>
|
||||
#include <numeric>
|
||||
#include <cassert>
|
||||
#include <cstddef>
|
||||
#include <cstdio>
|
||||
#include <cstdlib>
|
||||
#include <cstring>
|
||||
@ -1890,7 +1891,7 @@ class BumpPointerAllocator {
|
||||
static constexpr size_t AllocSize = 4096;
|
||||
static constexpr size_t UsableAllocSize = AllocSize - sizeof(BlockMeta);
|
||||
|
||||
alignas(16) char InitialBuffer[AllocSize];
|
||||
alignas(std::max_align_t) char InitialBuffer[AllocSize];
|
||||
BlockMeta* BlockList = nullptr;
|
||||
|
||||
void grow() {
|
||||
|
@ -17,6 +17,7 @@
|
||||
#include <cassert>
|
||||
#include <cctype>
|
||||
#include <cstdio>
|
||||
#include <cstddef>
|
||||
#include <cstdlib>
|
||||
#include <cstring>
|
||||
#include <numeric>
|
||||
@ -1950,7 +1951,7 @@ class BumpPointerAllocator {
|
||||
static constexpr size_t AllocSize = 4096;
|
||||
static constexpr size_t UsableAllocSize = AllocSize - sizeof(BlockMeta);
|
||||
|
||||
alignas(16) char InitialBuffer[AllocSize];
|
||||
alignas(std::max_align_t) char InitialBuffer[AllocSize];
|
||||
BlockMeta* BlockList = nullptr;
|
||||
|
||||
void grow() {
|
||||
|
Loading…
x
Reference in New Issue
Block a user