Temporary workaround to fix MSVC 2012 build problems

llvm-svn: 228788
This commit is contained in:
Andrew Kaylor 2015-02-11 02:16:34 +00:00
parent b3775df32e
commit 7ad134a746
1 changed files with 11 additions and 1 deletions

View File

@ -18,7 +18,17 @@
using namespace llvm;
namespace {
template <typename ArgType, typename RetType = ArgType>
template <typename ArgType>
ArgType PrivateGetDIAValue(IDiaSymbol *Symbol,
HRESULT (__stdcall IDiaSymbol::*Method)(ArgType *)) {
ArgType Value;
if (S_OK == (Symbol->*Method)(&Value))
return static_cast<ArgType>(Value);
return ArgType();
}
template <typename ArgType, typename RetType>
RetType PrivateGetDIAValue(IDiaSymbol *Symbol,
HRESULT (__stdcall IDiaSymbol::*Method)(ArgType *)) {
ArgType Value;