Browse Source

Added ASTVisitor option to not visit template specialization arguments.

pull/1/head
triton 12 years ago
parent
commit
4ffa945ce9
  1. 7
      src/Bridge/ASTVisitor.cs

7
src/Bridge/ASTVisitor.cs

@ -29,6 +29,7 @@ namespace CppSharp @@ -29,6 +29,7 @@ namespace CppSharp
public bool VisitNamespaceVariables = true;
public bool VisitFunctionParameters = true;
public bool VisitTemplateArguments = true;
}
/// <summary>
@ -134,6 +135,11 @@ namespace CppSharp @@ -134,6 +135,11 @@ namespace CppSharp
public virtual bool VisitTemplateSpecializationType(TemplateSpecializationType template,
TypeQualifiers quals)
{
if (!VisitType(template, quals))
return false;
if (Options.VisitTemplateArguments)
{
foreach (var arg in template.Arguments)
{
@ -149,6 +155,7 @@ namespace CppSharp @@ -149,6 +155,7 @@ namespace CppSharp
break;
}
}
}
return template.Template.Visit(this);
}

Loading…
Cancel
Save