Ignore dependent type for now

This commit is contained in:
Jonathan Müller 2017-04-11 20:31:39 +02:00
commit 5d95c1ed5d

View file

@ -470,7 +470,6 @@ namespace
case CXType_Vector: case CXType_Vector:
case CXType_ObjCInterface: case CXType_ObjCInterface:
case CXType_ObjCObjectPointer: case CXType_ObjCObjectPointer:
case CXType_Dependent:
{ {
auto msg = detail::format("unexpected type of kind '", auto msg = detail::format("unexpected type of kind '",
detail::get_type_kind_spelling(type).c_str(), "'"); detail::get_type_kind_spelling(type).c_str(), "'");
@ -478,6 +477,7 @@ namespace
context.logger->log("libclang parser", diagnostic{msg, location, severity::warning}); context.logger->log("libclang parser", diagnostic{msg, location, severity::warning});
} }
// fallthrough // fallthrough
case CXType_Dependent: // seems to have something to do with expressions, just ignore that (for now?)
case CXType_Unexposed: case CXType_Unexposed:
if (auto ftype = try_parse_function_type(context, cur, type)) if (auto ftype = try_parse_function_type(context, cur, type))
// guess what: after you've called clang_getPointeeType() on a function pointer // guess what: after you've called clang_getPointeeType() on a function pointer