Browse Source

Fixed parsing of dependent member pointer types.

Partial fix for https://github.com/mono/CppSharp/issues/664.
pull/667/head
Joao Matos 9 years ago
parent
commit
d4a2a7ea25
  1. 3
      src/CppParser/Parser.cpp
  2. 9
      tests/Common/Common.h

3
src/CppParser/Parser.cpp

@ -2421,7 +2421,8 @@ static bool CanCheckCodeGenInfo(clang::Sema& S, const clang::Type* Ty) @@ -2421,7 +2421,8 @@ static bool CanCheckCodeGenInfo(clang::Sema& S, const clang::Type* Ty)
{
auto FinalType = GetFinalType(Ty);
if (FinalType->isDependentType() || FinalType->isInstantiationDependentType())
if (Ty->isDependentType() || FinalType->isDependentType() ||
FinalType->isInstantiationDependentType())
return false;
if (auto RT = FinalType->getAs<clang::RecordType>())

9
tests/Common/Common.h

@ -1,4 +1,4 @@ @@ -1,4 +1,4 @@
#include "../Tests.h"
#include "../Tests.h"
#include "AnotherUnit.h"
#ifdef _WIN32
@ -967,6 +967,13 @@ namespace boost @@ -967,6 +967,13 @@ namespace boost
{
typedef detail::swallow_assign type;
};
template<class T>
struct is_class_or_union
{
template <class U>
static char is_class_or_union_tester(void(U::*)(void));
};
}
template <std::size_t N, std::size_t... I>

Loading…
Cancel
Save