[llvm-commits] [llvm] r173632 - Privitize some the copy c'tor and assignment operator of uniquified objects.

Bill Wendling isanbard at gmail.com
Sun Jan 27 13:38:03 PST 2013


Author: void
Date: Sun Jan 27 15:38:03 2013
New Revision: 173632

URL: http://llvm.org/viewvc/llvm-project?rev=173632&view=rev
Log:
Privitize some the copy c'tor and assignment operator of uniquified objects.

Modified:
    llvm/trunk/lib/IR/AttributeImpl.h

Modified: llvm/trunk/lib/IR/AttributeImpl.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/IR/AttributeImpl.h?rev=173632&r1=173631&r2=173632&view=diff
==============================================================================
--- llvm/trunk/lib/IR/AttributeImpl.h (original)
+++ llvm/trunk/lib/IR/AttributeImpl.h Sun Jan 27 15:38:03 2013
@@ -32,6 +32,10 @@ class AttributeImpl : public FoldingSetN
   LLVMContext &Context;
   Constant *Data;
   SmallVector<Constant*, 0> 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 FoldingS
 
   AttributeSetNode(ArrayRef<Attribute> 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<Attribute> Attrs);
 





More information about the llvm-commits mailing list