[llvm-commits] [llvm] r128054 - /llvm/trunk/include/llvm/ADT/IntrusiveRefCntPtr.h

Ted Kremenek kremenek at apple.com
Mon Mar 21 18:15:08 PDT 2011


Author: kremenek
Date: Mon Mar 21 20:15:07 2011
New Revision: 128054

URL: http://llvm.org/viewvc/llvm-project?rev=128054&view=rev
Log:
Relax access control on 'Release' method of RefCountedBase.

Modified:
    llvm/trunk/include/llvm/ADT/IntrusiveRefCntPtr.h

Modified: llvm/trunk/include/llvm/ADT/IntrusiveRefCntPtr.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/ADT/IntrusiveRefCntPtr.h?rev=128054&r1=128053&r2=128054&view=diff
==============================================================================
--- llvm/trunk/include/llvm/ADT/IntrusiveRefCntPtr.h (original)
+++ llvm/trunk/include/llvm/ADT/IntrusiveRefCntPtr.h Mon Mar 21 20:15:07 2011
@@ -44,7 +44,7 @@
   class RefCountedBase {
     unsigned ref_cnt;
 
-  protected:
+  public:
     RefCountedBase() : ref_cnt(0) {}
 
     void Retain() { ++ref_cnt; }
@@ -52,8 +52,6 @@
       assert (ref_cnt > 0 && "Reference count is already zero.");
       if (--ref_cnt == 0) delete static_cast<Derived*>(this);
     }
-
-    friend class IntrusiveRefCntPtr<Derived>;
   };
 
 //===----------------------------------------------------------------------===//





More information about the llvm-commits mailing list