aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Sema/TypeLocBuilder.h
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Sema/TypeLocBuilder.h')
-rw-r--r--lib/Sema/TypeLocBuilder.h12
1 files changed, 5 insertions, 7 deletions
diff --git a/lib/Sema/TypeLocBuilder.h b/lib/Sema/TypeLocBuilder.h
index 1e6883926a80..738f731c9fe2 100644
--- a/lib/Sema/TypeLocBuilder.h
+++ b/lib/Sema/TypeLocBuilder.h
@@ -39,18 +39,16 @@ class TypeLocBuilder {
/// The inline buffer.
enum { BufferMaxAlignment = alignof(void *) };
- llvm::AlignedCharArray<BufferMaxAlignment, InlineCapacity> InlineBuffer;
+ alignas(BufferMaxAlignment) char InlineBuffer[InlineCapacity];
unsigned NumBytesAtAlign4, NumBytesAtAlign8;
- public:
+public:
TypeLocBuilder()
- : Buffer(InlineBuffer.buffer), Capacity(InlineCapacity),
- Index(InlineCapacity), NumBytesAtAlign4(0), NumBytesAtAlign8(0)
- {
- }
+ : Buffer(InlineBuffer), Capacity(InlineCapacity), Index(InlineCapacity),
+ NumBytesAtAlign4(0), NumBytesAtAlign8(0) {}
~TypeLocBuilder() {
- if (Buffer != InlineBuffer.buffer)
+ if (Buffer != InlineBuffer)
delete[] Buffer;
}