#include "LLVMContextImpl.h"
#include "llvm/ADT/STLExtras.h"
-#include "llvm/Attributes.h"
-#include "llvm/Module.h"
+#include "llvm/IR/Attributes.h"
+#include "llvm/IR/Module.h"
#include <algorithm>
using namespace llvm;
Int16Ty(C, 16),
Int32Ty(C, 32),
Int64Ty(C, 64) {
- DiagHandler = 0;
- DiagContext = 0;
+ InlineAsmDiagHandler = 0;
+ InlineAsmDiagContext = 0;
+ DiagnosticHandler = 0;
+ DiagnosticContext = 0;
NamedStructTypesUniqueID = 0;
}
delete &*Elem;
}
+ // Destroy attribute node lists.
+ for (FoldingSetIterator<AttributeSetNode> I = AttrsSetNodes.begin(),
+ E = AttrsSetNodes.end(); I != E; ) {
+ FoldingSetIterator<AttributeSetNode> Elem = I++;
+ delete &*Elem;
+ }
+
// Destroy MDNodes. ~MDNode can move and remove nodes between the MDNodeSet
// and the NonUniquedMDNodes sets, so copy the values out first.
SmallVector<MDNode*, 8> MDNodes;