diff options
Diffstat (limited to 'include/clang/AST/CommentVisitor.h')
-rw-r--r-- | include/clang/AST/CommentVisitor.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/clang/AST/CommentVisitor.h b/include/clang/AST/CommentVisitor.h index 159725af26..47867a634f 100644 --- a/include/clang/AST/CommentVisitor.h +++ b/include/clang/AST/CommentVisitor.h @@ -24,6 +24,9 @@ public: return static_cast<ImplClass*>(this)->visit ## NAME(static_cast<PTR(CLASS)>(C)) RetTy visit(PTR(Comment) C) { + if (!C) + return RetTy(); + switch (C->getCommentKind()) { default: llvm_unreachable("Unknown comment kind!"); #define ABSTRACT_COMMENT(COMMENT) |