From 6fec233a1e4b26be2f69e02884d4f3c2a2c4a437 Mon Sep 17 00:00:00 2001 From: Jeffrey Yasskin Date: Sun, 7 Mar 2010 19:26:40 +0000 Subject: Roll back r97918 again. Just configuring against llvm-gcc wasn't enough to run the FrontendC* tests. :( git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@97921 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/llvm/Metadata.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'include') diff --git a/include/llvm/Metadata.h b/include/llvm/Metadata.h index cecb7da..e536322 100644 --- a/include/llvm/Metadata.h +++ b/include/llvm/Metadata.h @@ -108,6 +108,9 @@ class MDNode : public Value, public FoldingSetNode { /// node with T. void replaceOperand(MDNodeOperand *Op, Value *NewVal); ~MDNode(); + /// replaceAllOperandsWithNull - This is used while destroying llvm context to + /// gracefully delete all nodes. This method replaces all operands with null. + void replaceAllOperandsWithNull(); protected: explicit MDNode(LLVMContext &C, Value *const *Vals, unsigned NumVals, @@ -163,7 +166,9 @@ private: bool isNotUniqued() const { return (getSubclassDataFromValue() & NotUniquedBit) != 0; } - void setIsNotUniqued(); + void setIsNotUniqued() { + setValueSubclassData(getSubclassDataFromValue() | NotUniquedBit); + } // Shadow Value::setValueSubclassData with a private forwarding method so that // any future subclasses cannot accidentally use it. -- cgit v1.1