aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDmitri Gribenko <gribozavr@gmail.com>2013-04-10 18:43:09 +0000
committerDmitri Gribenko <gribozavr@gmail.com>2013-04-10 18:43:09 +0000
commit0e7f2bb1810a4e5e62a8e247460cd26f981d0827 (patch)
tree8dad27954120bd5a9f29c9c9ea3cf78f553c73ad
parentb55dd767b2db98f6e4f9128514cb93fe156e7d75 (diff)
-fparse-all-comments: remove redundant check, as suggested by Fariborz Jahanian
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@179204 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--include/clang/AST/RawCommentList.h2
-rw-r--r--test/Index/parse-all-comments.c10
2 files changed, 10 insertions, 2 deletions
diff --git a/include/clang/AST/RawCommentList.h b/include/clang/AST/RawCommentList.h
index 7e8bf044c1..84a6e96fa0 100644
--- a/include/clang/AST/RawCommentList.h
+++ b/include/clang/AST/RawCommentList.h
@@ -89,7 +89,7 @@ public:
/// Returns true if this comment any kind of a documentation comment.
bool isDocumentation() const LLVM_READONLY {
- return !isInvalid() && (!isOrdinary() || ParseAllComments);
+ return !isInvalid() && !isOrdinary();
}
/// Returns whether we are parsing all comments.
diff --git a/test/Index/parse-all-comments.c b/test/Index/parse-all-comments.c
index d7dce364e2..ac31f5b74e 100644
--- a/test/Index/parse-all-comments.c
+++ b/test/Index/parse-all-comments.c
@@ -15,6 +15,12 @@ void notdoxy3(void);
/** Doxygen comment. isdoxy4 IS_DOXYGEN_SINGLE */
void isdoxy4(void);
+/*! Doxygen comment. isdoxy5 IS_DOXYGEN_SINGLE */
+void isdoxy5(void);
+
+/// Doxygen comment. isdoxy6 IS_DOXYGEN_SINGLE
+void isdoxy6(void);
+
/* BLOCK_ORDINARY_COMMENT */
// ORDINARY COMMENT
/// This is a BCPL comment. IS_DOXYGEN_START
@@ -45,4 +51,6 @@ void multi_line_comment_plus_ordinary(int);
// CHECK: parse-all-comments.c:10:6: FunctionDecl=notdoxy2:{{.*}} notdoxy2 NOT_DOXYGEN
// CHECK: parse-all-comments.c:13:6: FunctionDecl=notdoxy3:{{.*}} notdoxy3 NOT_DOXYGEN
// CHECK: parse-all-comments.c:16:6: FunctionDecl=isdoxy4:{{.*}} isdoxy4 IS_DOXYGEN_SINGLE
-// CHECK: parse-all-comments.c:23:6: FunctionDecl=multi_line_comment_plus_ordinary:{{.*}} BLOCK_ORDINARY_COMMENT {{.*}} ORDINARY COMMENT {{.*}} IS_DOXYGEN_START {{.*}} IS_DOXYGEN_END
+// CHECK: parse-all-comments.c:19:6: FunctionDecl=isdoxy5:{{.*}} isdoxy5 IS_DOXYGEN_SINGLE
+// CHECK: parse-all-comments.c:22:6: FunctionDecl=isdoxy6:{{.*}} isdoxy6 IS_DOXYGEN_SINGLE
+// CHECK: parse-all-comments.c:29:6: FunctionDecl=multi_line_comment_plus_ordinary:{{.*}} BLOCK_ORDINARY_COMMENT {{.*}} ORDINARY COMMENT {{.*}} IS_DOXYGEN_START {{.*}} IS_DOXYGEN_END