From d787a5346952ee7c00e1a5134708fe86b55e6c37 Mon Sep 17 00:00:00 2001 From: Ms2ger Date: Tue, 2 Oct 2012 10:24:12 +0200 Subject: [PATCH] Bug 792379 - Don't include prtypes.h in base/basictypes.h; r=cjones --- ipc/chromium/src/base/basictypes.h | 12 ------------ xpcom/glue/nsTraceRefcnt.h | 16 ++++++++-------- xpcom/glue/pldhash.h | 1 + 3 files changed, 9 insertions(+), 20 deletions(-) diff --git a/ipc/chromium/src/base/basictypes.h b/ipc/chromium/src/base/basictypes.h index 9811408ff4d..16a19a9f0d7 100644 --- a/ipc/chromium/src/base/basictypes.h +++ b/ipc/chromium/src/base/basictypes.h @@ -12,18 +12,6 @@ #error You_must_include_basictypes.h_before_prtypes.h! #endif -#ifndef NO_NSPR_10_SUPPORT -#define NO_NSPR_10_SUPPORT -#define NO_NSPR_10_SUPPORT_SAVE -#endif - -#include "prtypes.h" - -#ifdef NO_NSPR_10_SUPPORT_SAVE -#undef NO_NSPR_10_SUPPORT_SAVE -#undef NO_NSPR_10_SUPPORT -#endif - #include // So we can set the bounds of our types #include // For size_t #include // for memcpy diff --git a/xpcom/glue/nsTraceRefcnt.h b/xpcom/glue/nsTraceRefcnt.h index 1060078395e..b132540e77a 100644 --- a/xpcom/glue/nsTraceRefcnt.h +++ b/xpcom/glue/nsTraceRefcnt.h @@ -16,24 +16,24 @@ NS_LogRelease((_p), (_rc), (_type)) #define MOZ_COUNT_CTOR(_type) \ -PR_BEGIN_MACRO \ +do { \ NS_LogCtor((void*)this, #_type, sizeof(*this)); \ -PR_END_MACRO +} while (0) #define MOZ_COUNT_CTOR_INHERITED(_type, _base) \ -PR_BEGIN_MACRO \ +do { \ NS_LogCtor((void*)this, #_type, sizeof(*this) - sizeof(_base)); \ -PR_END_MACRO +} while (0) #define MOZ_COUNT_DTOR(_type) \ -PR_BEGIN_MACRO \ +do { \ NS_LogDtor((void*)this, #_type, sizeof(*this)); \ -PR_END_MACRO +} while (0) #define MOZ_COUNT_DTOR_INHERITED(_type, _base) \ -PR_BEGIN_MACRO \ +do { \ NS_LogDtor((void*)this, #_type, sizeof(*this) - sizeof(_base)); \ -PR_END_MACRO +} while (0) /* nsCOMPtr.h allows these macros to be defined by clients * These logging functions require dynamic_cast, so they don't diff --git a/xpcom/glue/pldhash.h b/xpcom/glue/pldhash.h index 7ee953a7c77..5148277b113 100644 --- a/xpcom/glue/pldhash.h +++ b/xpcom/glue/pldhash.h @@ -10,6 +10,7 @@ * * Try to keep this file in sync with js/src/jsdhash.h. */ +#include "mozilla/Types.h" #include "nscore.h" #ifdef __cplusplus