Bug 720759 - Export mfbt's guard object classes to avoid warnings using them in exported APIs. r=Ms2ger
authorJeff Walden <jwalden@mit.edu>
Tue, 24 Jan 2012 09:22:47 -0800
changeset 88098 ec9a6b8c81d8315648b09b0fbbd5dc3a0a0dd1ff
parent 88097 33ab41faf05e25a609bf16f0dab117c64af54606
child 88099 5d572733c31ebb146365569b04d6976d62687001
push id129
push userffxbld
push dateFri, 20 Apr 2012 19:40:49 +0000
treeherdermozilla-release@5bcfa0da3be9 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersMs2ger
bugs720759
milestone12.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 720759 - Export mfbt's guard object classes to avoid warnings using them in exported APIs. r=Ms2ger
mfbt/GuardObjects.h
--- a/mfbt/GuardObjects.h
+++ b/mfbt/GuardObjects.h
@@ -39,16 +39,17 @@
  * ***** END LICENSE BLOCK ***** */
 
 /* Implementation of macros to ensure correct use of RAII Auto* objects. */
 
 #ifndef mozilla_GuardObjects_h
 #define mozilla_GuardObjects_h
 
 #include "mozilla/Assertions.h"
+#include "mozilla/Types.h"
 
 #ifdef __cplusplus
 
 #ifdef DEBUG
 
 namespace mozilla {
 namespace detail {
 /*
@@ -94,34 +95,34 @@ namespace detail {
  *     a base class that also uses these macros
  *   MOZ_GUARD_OBJECT_NOTIFIER_INIT is a statement that belongs in each
  *     constructor. It uses the parameter declared by
  *     MOZ_GUARD_OBJECT_NOTIFIER_PARAM.
  *
  * For more details, and examples of using these macros, see
  * https://developer.mozilla.org/en/Using_RAII_classes_in_Mozilla
  */
-class GuardObjectNotifier
+class MFBT_API(GuardObjectNotifier)
 {
   private:
     bool* statementDone;
 
   public:
     GuardObjectNotifier() : statementDone(NULL) {}
 
     ~GuardObjectNotifier() {
         *statementDone = true;
     }
 
     void setStatementDone(bool* statementIsDone) {
         statementDone = statementIsDone;
     }
 };
 
-class GuardObjectNotificationReceiver
+class MFBT_API(GuardObjectNotificationReceiver)
 {
   private:
     bool statementDone;
 
   public:
     GuardObjectNotificationReceiver() : statementDone(false) {}
 
     ~GuardObjectNotificationReceiver() {