Change from alignof to llvm::alignOf to appease Visual Studio

llvm-svn: 239424
This commit is contained in:
Pete Cooper 2015-06-09 18:50:18 +00:00
parent 234b875690
commit 5615c6613a
1 changed files with 2 additions and 2 deletions

View File

@ -25,9 +25,9 @@ void *MCSymbol::operator new(size_t s, NameEntryTy *Name, MCContext &Ctx) {
// For safety, ensure that the alignment of a pointer is enough for an
// MCSymbol. This also ensures we don't need padding between the name and
// symbol.
assert(alignOf<MCSymbol>() <= alignof(NameEntryTy *) &&
assert(alignOf<MCSymbol>() <= alignOf<NameEntryTy *>() &&
"Bad alignment of MCSymbol");
void *Storage = Ctx.allocate(Size, alignof(NameEntryTy *));
void *Storage = Ctx.allocate(Size, alignOf<NameEntryTy *>());
NameEntryTy **Start = static_cast<NameEntryTy**>(Storage);
NameEntryTy **End = Start + (Name ? 1 : 0);
return End;