From 97b4f70b2e1f5b1cb9f85c6765192a67b12b983a Mon Sep 17 00:00:00 2001 From: Bill Wendling Date: Sun, 27 Jan 2013 21:38:03 +0000 Subject: [PATCH] Privitize some the copy c'tor and assignment operator of uniquified objects. llvm-svn: 173632 --- llvm/lib/IR/AttributeImpl.h | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/llvm/lib/IR/AttributeImpl.h b/llvm/lib/IR/AttributeImpl.h index c565364..b4fb0c0 100644 --- a/llvm/lib/IR/AttributeImpl.h +++ b/llvm/lib/IR/AttributeImpl.h @@ -32,6 +32,10 @@ class AttributeImpl : public FoldingSetNode { LLVMContext &Context; Constant *Data; SmallVector Vals; + + // AttributesImpl is uniqued, these should not be publicly available. + void operator=(const AttributeImpl &) LLVM_DELETED_FUNCTION; + AttributeImpl(const AttributeImpl &) LLVM_DELETED_FUNCTION; public: explicit AttributeImpl(LLVMContext &C, uint64_t data); explicit AttributeImpl(LLVMContext &C, Attribute::AttrKind data); @@ -78,6 +82,10 @@ class AttributeSetNode : public FoldingSetNode { AttributeSetNode(ArrayRef Attrs) : AttrList(Attrs.begin(), Attrs.end()) {} + + // AttributesSetNode is uniqued, these should not be publicly available. + void operator=(const AttributeSetNode &) LLVM_DELETED_FUNCTION; + AttributeSetNode(const AttributeSetNode &) LLVM_DELETED_FUNCTION; public: static AttributeSetNode *get(LLVMContext &C, ArrayRef Attrs); -- 2.7.4