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 86504 ec9a6b8c81d8315648b09b0fbbd5dc3a0a0dd1ff
parent 86503 33ab41faf05e25a609bf16f0dab117c64af54606
child 86505 5d572733c31ebb146365569b04d6976d62687001
push id805
push userakeybl@mozilla.com
push dateWed, 01 Feb 2012 18:17:35 +0000
treeherdermozilla-aurora@6fb3bf232436 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersMs2ger
bugs720759
milestone12.0a1
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() {