CXXInfo memory should be released after calling the destructor
instead of before. The wrong order had no effect since Deallocate() does nothing right now, but we may replace allocator in the future. llvm-svn: 209567
This commit is contained in:
parent
e471e43484
commit
188cafb030
|
@ -21,8 +21,8 @@ void ASTRecordLayout::Destroy(ASTContext &Ctx) {
|
|||
if (FieldOffsets)
|
||||
Ctx.Deallocate(FieldOffsets);
|
||||
if (CXXInfo) {
|
||||
Ctx.Deallocate(CXXInfo);
|
||||
CXXInfo->~CXXRecordLayoutInfo();
|
||||
Ctx.Deallocate(CXXInfo);
|
||||
}
|
||||
this->~ASTRecordLayout();
|
||||
Ctx.Deallocate(this);
|
||||
|
|
Loading…
Reference in New Issue