9#ifndef LLVM_CLANG_AST_COMMENTVISITOR_H
10#define LLVM_CLANG_AST_COMMENTVISITOR_H
13#include "llvm/ADT/STLExtras.h"
14#include "llvm/Support/ErrorHandling.h"
18template <
template <
typename>
class Ptr,
typename ImplClass,
19 typename RetTy = void,
class... ParamTys>
22#define PTR(CLASS) typename Ptr<CLASS>::type
23#define DISPATCH(NAME, CLASS) \
24 return static_cast<ImplClass *>(this)->visit##NAME( \
25 static_cast<PTR(CLASS)>(C), std::forward<ParamTys>(P)...)
31 switch (
C->getCommentKind()) {
32 default: llvm_unreachable(
"Unknown comment kind!");
33#define ABSTRACT_COMMENT(COMMENT)
34#define COMMENT(CLASS, PARENT) \
35 case CommentKind::CLASS: \
36 DISPATCH(CLASS, CLASS);
37#include "clang/AST/CommentNodes.inc"
38#undef ABSTRACT_COMMENT
45#define ABSTRACT_COMMENT(COMMENT) COMMENT
46#define COMMENT(CLASS, PARENT) \
47 RetTy visit##CLASS(PTR(CLASS) C, ParamTys... P) { DISPATCH(PARENT, PARENT); }
48#include "clang/AST/CommentNodes.inc"
49#undef ABSTRACT_COMMENT
58template <
typename ImplClass,
typename RetTy = void,
class... ParamTys>
60 RetTy, ParamTys...> {};
62template <
typename ImplClass,
typename RetTy = void,
class... ParamTys>
The JSON file list parser is used to communicate input to InstallAPI.