For PR950:
[oota-llvm.git] / lib / VMCore / LeakDetector.cpp
index 7cf8e0d99aecebd7570f9e68877d077436e3bde5..39715fe48ceb6a6e12180122a198dd3d049ccc73 100644 (file)
@@ -12,6 +12,7 @@
 //===----------------------------------------------------------------------===//
 
 #include "llvm/Support/LeakDetector.h"
+#include "llvm/Support/Compiler.h"
 #include "llvm/Value.h"
 #include <iostream>
 #include <set>
@@ -19,17 +20,17 @@ using namespace llvm;
 
 namespace {
   template <class T>
-  struct PrinterTrait {
+  struct VISIBILITY_HIDDEN PrinterTrait {
     static void print(const T* P) { std::cerr << P; }
   };
 
   template<>
-  struct PrinterTrait<Value> {
+  struct VISIBILITY_HIDDEN PrinterTrait<Value> {
     static void print(const Value* P) { std::cerr << *P; }
   };
 
   template <typename T>
-  struct LeakDetectorImpl {
+  struct VISIBILITY_HIDDEN LeakDetectorImpl {
     LeakDetectorImpl(const char* const name) : Cache(0), Name(name) { }
 
     // Because the most common usage pattern, by far, is to add a