13#ifndef LLVM_CLANG_AST_ATTRVISITOR_H
14#define LLVM_CLANG_AST_ATTRVISITOR_H
20namespace attrvisitor {
23template <
template <
typename>
class Ptr,
typename ImplClass,
24 typename RetTy = void,
class... ParamTys>
27#define PTR(CLASS) typename Ptr<CLASS>::type
28#define DISPATCH(NAME) \
29 return static_cast<ImplClass *>(this)->Visit##NAME(static_cast<PTR(NAME)>(A))
37#include "clang/Basic/AttrList.inc"
39 llvm_unreachable(
"Attr that isn't part of AttrList.inc!");
45 RetTy Visit##NAME##Attr(PTR(NAME##Attr) A) { DISPATCH(Attr); }
46#include "clang/Basic/AttrList.inc"
60template <
typename ImplClass,
typename RetTy = void,
typename... ParamTys>
68template <
typename ImplClass,
typename RetTy = void,
typename... ParamTys>
A simple visitor class that helps create attribute visitors.
Attr - This represents one attribute.
attr::Kind getKind() const
A simple visitor class that helps create attribute visitors.
A simple visitor class that helps create attribute visitors.
RetTy VisitAttr(PTR(Attr))
The JSON file list parser is used to communicate input to InstallAPI.