Browse Source

Added stubbed support for pack expansions to the new parser as well.

Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
pull/193/head
Dimitar Dobrev 12 years ago
parent
commit
2605ac680d
  1. 2
      src/CppParser/AST.cpp
  2. 6
      src/CppParser/AST.h
  3. 4
      src/CppParser/Parser.cpp

2
src/CppParser/AST.cpp

@ -68,6 +68,8 @@ InjectedClassNameType::InjectedClassNameType() : Type(TypeKind::InjectedClassNam
DependentNameType::DependentNameType() : Type(TypeKind::DependentName) {} DependentNameType::DependentNameType() : Type(TypeKind::DependentName) {}
PackExpansionType::PackExpansionType() : Type(TypeKind::PackExpansion) {}
BuiltinType::BuiltinType() : CppSharp::CppParser::AST::Type(TypeKind::Builtin) {} BuiltinType::BuiltinType() : CppSharp::CppParser::AST::Type(TypeKind::Builtin) {}
// RawComment // RawComment

6
src/CppParser/AST.h

@ -28,6 +28,7 @@ enum struct TypeKind
TemplateParameterSubstitution, TemplateParameterSubstitution,
InjectedClassName, InjectedClassName,
DependentName, DependentName,
PackExpansion,
Builtin Builtin
}; };
@ -211,6 +212,11 @@ struct CS_API DependentNameType : public Type
DECLARE_TYPE_KIND(DependentName) DECLARE_TYPE_KIND(DependentName)
}; };
struct CS_API PackExpansionType : public Type
{
DECLARE_TYPE_KIND(PackExpansion)
};
enum struct PrimitiveType enum struct PrimitiveType
{ {
Null, Null,

4
src/CppParser/Parser.cpp

@ -1635,8 +1635,8 @@ Type* Parser::WalkType(clang::QualType QualType, clang::TypeLoc* TL,
} }
case clang::Type::PackExpansion: case clang::Type::PackExpansion:
{ {
// Ignored. // TODO: stubbed
return nullptr; Ty = new PackExpansionType();
} }
default: default:
{ {

Loading…
Cancel
Save