Instantiate Registry<GCStrategy> in LLVMCore, to let it available on Win32 DLL.
authorNAKAMURA Takumi <geek4civic@gmail.com>
Sun, 25 Jan 2015 15:05:36 +0000 (15:05 +0000)
committerNAKAMURA Takumi <geek4civic@gmail.com>
Sun, 25 Jan 2015 15:05:36 +0000 (15:05 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@227046 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/IR/GCStrategy.h
lib/IR/GCStrategy.cpp

index 15acfe443cd7364c8da0ff8495e928d607ccdec3..c9b0a848ab7c943861f9a9781085a8798d4b4ea4 100644 (file)
@@ -188,6 +188,9 @@ public:
 /// register your GCMetadataPrinter subclass with the
 /// GCMetadataPrinterRegistery as well.
 typedef Registry<GCStrategy> GCRegistry;
+
+/// GCStrategy is instantiated in GCStrategy.cpp.
+extern template class Registry<GCStrategy>;
 }
 
 #endif
index 56e6946daf69b91da006408f2547811b76ead93a..b451310f7f0c1b487704e78c7af15ec95f7cb3ad 100644 (file)
@@ -14,6 +14,8 @@
 
 #include "llvm/IR/GCStrategy.h"
 
+template class llvm::Registry<llvm::GCStrategy>;
+
 using namespace llvm;
 
 GCStrategy::GCStrategy()