|
@@ -13,6 +13,7 @@
|
|
#include "clang/Basic/Diagnostic.h"
|
|
#include "clang/Basic/Diagnostic.h"
|
|
#include "clang/Basic/SourceManager.h"
|
|
#include "clang/Basic/SourceManager.h"
|
|
#include "clang/Frontend/CompilerInvocation.h"
|
|
#include "clang/Frontend/CompilerInvocation.h"
|
|
|
|
+#include "clang/Frontend/Utils.h"
|
|
#include "clang/Lex/ModuleLoader.h"
|
|
#include "clang/Lex/ModuleLoader.h"
|
|
#include "llvm/ADT/ArrayRef.h"
|
|
#include "llvm/ADT/ArrayRef.h"
|
|
#include "llvm/ADT/DenseMap.h"
|
|
#include "llvm/ADT/DenseMap.h"
|
|
@@ -325,6 +326,7 @@ public:
|
|
}
|
|
}
|
|
|
|
|
|
void resetAndLeakFileManager() {
|
|
void resetAndLeakFileManager() {
|
|
|
|
+ BuryPointer(FileMgr.getPtr());
|
|
FileMgr.resetWithoutRelease();
|
|
FileMgr.resetWithoutRelease();
|
|
}
|
|
}
|
|
|
|
|
|
@@ -344,6 +346,7 @@ public:
|
|
}
|
|
}
|
|
|
|
|
|
void resetAndLeakSourceManager() {
|
|
void resetAndLeakSourceManager() {
|
|
|
|
+ BuryPointer(SourceMgr.getPtr());
|
|
SourceMgr.resetWithoutRelease();
|
|
SourceMgr.resetWithoutRelease();
|
|
}
|
|
}
|
|
|
|
|
|
@@ -363,6 +366,7 @@ public:
|
|
}
|
|
}
|
|
|
|
|
|
void resetAndLeakPreprocessor() {
|
|
void resetAndLeakPreprocessor() {
|
|
|
|
+ BuryPointer(PP.getPtr());
|
|
PP.resetWithoutRelease();
|
|
PP.resetWithoutRelease();
|
|
}
|
|
}
|
|
|
|
|
|
@@ -381,6 +385,7 @@ public:
|
|
}
|
|
}
|
|
|
|
|
|
void resetAndLeakASTContext() {
|
|
void resetAndLeakASTContext() {
|
|
|
|
+ BuryPointer(Context.getPtr());
|
|
Context.resetWithoutRelease();
|
|
Context.resetWithoutRelease();
|
|
}
|
|
}
|
|
|
|
|