From 97f9b0db4178b9747e87caeadd147b6abb4fbedf Mon Sep 17 00:00:00 2001 From: "scc%netscape.com" Date: Fri, 23 Jul 1999 01:18:49 +0000 Subject: [PATCH] the fix is to |#include |. I tested on several versions of SunOS with different compilers, linux, and Mac. Uncommenting the problematic code. git-svn-id: svn://10.0.0.236/trunk@40769 18797224-902f-48f8-a5cc-f745e15eee43 --- mozilla/xpcom/ds/nsCppSharedAllocator.h | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/mozilla/xpcom/ds/nsCppSharedAllocator.h b/mozilla/xpcom/ds/nsCppSharedAllocator.h index f705f6f489b..c84fdb4ec21 100644 --- a/mozilla/xpcom/ds/nsCppSharedAllocator.h +++ b/mozilla/xpcom/ds/nsCppSharedAllocator.h @@ -3,6 +3,7 @@ #include "nsIAllocator.h" // for |nsAllocator| #include "nscore.h" // for |NS_XXX_CAST| +#include // to allow placement |new| // under Metrowerks (Mac), we don't have autoconf yet @@ -72,18 +73,11 @@ class nsCppSharedAllocator nsAllocator::Free(p); } -#if 0 - /* - Hmmm. Some platforms don't seem to have placement |new|. I'll comment this out - temporarily until I can come up with a fix. - */ - void construct( pointer p, const T& val ) { new (p) T(val); } -#endif void destroy( pointer p )