From 105a8585cf0fd5e87aa63378c3caa792531aeace Mon Sep 17 00:00:00 2001 From: "benjamin%smedbergs.us" Date: Tue, 8 Aug 2006 17:08:49 +0000 Subject: [PATCH] Bug 229875 - eliminate unnecssary public/virtual destructors. This patch changes all refcounted classes under xpcom/, which aren't inherited from or used on the stack, to have private, nonvirtual destructors. r=dougt, sr=dbaron. Original committer: bryner%brianryner.com Original revision: 1.7 Original date: 2004/01/15 06:14:12 --- xpcom/glue/nsArrayEnumerator.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/xpcom/glue/nsArrayEnumerator.cpp b/xpcom/glue/nsArrayEnumerator.cpp index 8443794236cb..c105622a7a08 100644 --- a/xpcom/glue/nsArrayEnumerator.cpp +++ b/xpcom/glue/nsArrayEnumerator.cpp @@ -110,7 +110,6 @@ public: // nsSimpleArrayEnumerator methods nsCOMArrayEnumerator() : mIndex(0) { } - virtual ~nsCOMArrayEnumerator(void); // specialized operator to make sure we make room for mValues void* operator new (size_t size, const nsCOMArray_base& aArray) CPP_THROW_NEW; @@ -118,6 +117,9 @@ public: ::operator delete(ptr); } +private: + ~nsCOMArrayEnumerator(void); + protected: PRUint32 mIndex; // current position PRUint32 mArraySize; // size of the array