• Home
  • Raw
  • Download

Lines Matching full:comments

1 //===--- RawCommentList.cpp - Processing raw comments -----------*- C++ -*-===//
186 comments::Lexer L(Allocator, Context.getDiagnostics(), in extractBriefText()
190 comments::BriefParser P(L, Context.getCommentCommandTraits()); in extractBriefText()
202 comments::FullComment *RawComment::parse(const ASTContext &Context, in parse()
208 comments::Lexer L(Context.getAllocator(), Context.getDiagnostics(), in parse()
212 comments::Sema S(Context.getAllocator(), Context.getSourceManager(), in parse()
217 comments::Parser P(L, S, Context.getAllocator(), Context.getSourceManager(), in parse()
277 // Check if the comments are not in source order. in addComment()
278 while (!Comments.empty() && in addComment()
279 !SourceMgr.isBeforeInTranslationUnit(Comments.back()->getLocStart(), in addComment()
281 // If they are, just pop a few last comments that don't fit. in addComment()
282 // This happens if an \#include directive contains comments. in addComment()
283 Comments.pop_back(); in addComment()
286 // Ordinary comments are not interesting for us. in addComment()
292 if (Comments.empty()) { in addComment()
293 Comments.push_back(new (Allocator) RawComment(RC)); in addComment()
297 const RawComment &C1 = *Comments.back(); in addComment()
300 // Merge comments only if there is only whitespace between them. in addComment()
301 // Can't merge trailing and non-trailing comments unless the second is in addComment()
312 // Merge comments if they are on same or consecutive lines. in addComment()
320 *Comments.back() = RawComment(SourceMgr, MergedRange, true, in addComment()
323 Comments.push_back(new (Allocator) RawComment(RC)); in addComment()
329 MergedComments.reserve(Comments.size() + DeserializedComments.size()); in addDeserializedComments()
331 std::merge(Comments.begin(), Comments.end(), in addDeserializedComments()
335 std::swap(Comments, MergedComments); in addDeserializedComments()