clang 20.0.0git
|
Doxygen comment parser. More...
#include "clang/AST/CommentParser.h"
Friends | |
class | TextTokenRetokenizer |
Doxygen comment parser.
Definition at line 29 of file CommentParser.h.
clang::comments::Parser::Parser | ( | Lexer & | L, |
Sema & | S, | ||
llvm::BumpPtrAllocator & | Allocator, | ||
const SourceManager & | SourceMgr, | ||
DiagnosticsEngine & | Diags, | ||
const CommandTraits & | Traits | ||
) |
Definition at line 386 of file CommentParser.cpp.
BlockCommandComment * clang::comments::Parser::parseBlockCommand | ( | ) |
Definition at line 472 of file CommentParser.cpp.
References clang::comments::Sema::actOnBlockCommandArgs(), clang::comments::Sema::actOnBlockCommandFinish(), clang::comments::Sema::actOnBlockCommandStart(), clang::comments::Sema::actOnParagraphComment(), clang::comments::Sema::actOnParamCommandFinish(), clang::comments::Sema::actOnParamCommandStart(), clang::comments::Sema::actOnTParamCommandFinish(), clang::comments::Sema::actOnTParamCommandStart(), clang::comments::tok::at_command, clang::comments::tok::backslash_command, clang::Block, clang::comments::CMK_At, clang::comments::CMK_Backslash, clang::comments::Token::getCommandID(), clang::comments::CommandTraits::getCommandInfo(), clang::comments::Token::getEndLocation(), clang::comments::Token::getLocation(), clang::comments::Token::is(), clang::comments::CommandInfo::IsParamCommand, clang::comments::CommandInfo::IsParCommand, clang::comments::CommandInfo::IsThrowsCommand, clang::comments::CommandInfo::IsTParamCommand, clang::comments::tok::newline, clang::comments::CommandInfo::NumArgs, parseCommandArgs(), parseParagraphOrBlockCommand(), parseParamCommandArgs(), parseParCommandArgs(), parseThrowCommandArgs(), parseTParamCommandArgs(), and clang::comments::TextTokenRetokenizer::putBackLeftoverTokens().
Referenced by parseParagraphOrBlockCommand().
BlockContentComment * clang::comments::Parser::parseBlockContent | ( | ) |
Definition at line 887 of file CommentParser.cpp.
References clang::comments::tok::at_command, clang::comments::tok::backslash_command, clang::comments::tok::eof, clang::comments::Token::getKind(), clang::comments::tok::html_end_tag, clang::comments::tok::html_equals, clang::comments::tok::html_greater, clang::comments::tok::html_ident, clang::comments::tok::html_quoted_string, clang::comments::tok::html_slash_greater, clang::comments::tok::html_start_tag, clang::comments::tok::newline, parseParagraphOrBlockCommand(), parseVerbatimBlock(), parseVerbatimLine(), clang::comments::tok::text, clang::comments::tok::unknown_command, clang::comments::tok::verbatim_block_begin, clang::comments::tok::verbatim_block_end, clang::comments::tok::verbatim_block_line, clang::comments::tok::verbatim_line_name, and clang::comments::tok::verbatim_line_text.
Referenced by parseFullComment().
ArrayRef< Comment::Argument > clang::comments::Parser::parseCommandArgs | ( | TextTokenRetokenizer & | Retokenizer, |
unsigned | NumArgs | ||
) |
Definition at line 423 of file CommentParser.cpp.
References clang::comments::Token::getEndLocation(), clang::comments::Token::getLocation(), clang::comments::Token::getText(), and clang::comments::TextTokenRetokenizer::lexWord().
Referenced by parseBlockCommand(), and parseInlineCommand().
FullComment * clang::comments::Parser::parseFullComment | ( | ) |
Definition at line 918 of file CommentParser.cpp.
References clang::comments::Sema::actOnFullComment(), clang::comments::Sema::copyArray(), clang::comments::tok::eof, clang::comments::Token::is(), clang::comments::Token::isNot(), clang::comments::tok::newline, and parseBlockContent().
HTMLEndTagComment * clang::comments::Parser::parseHTMLEndTag | ( | ) |
Definition at line 699 of file CommentParser.cpp.
References clang::comments::Sema::actOnHTMLEndTag(), clang::comments::Token::getHTMLTagEndName(), clang::comments::Token::getLocation(), clang::comments::tok::html_end_tag, clang::comments::tok::html_greater, clang::comments::Token::is(), and Loc.
Referenced by parseParagraphOrBlockCommand().
HTMLStartTagComment * clang::comments::Parser::parseHTMLStartTag | ( | ) |
Definition at line 598 of file CommentParser.cpp.
References clang::comments::Sema::actOnHTMLStartTagFinish(), clang::comments::Sema::actOnHTMLStartTagStart(), clang::comments::Sema::copyArray(), clang::comments::Token::getEndLocation(), clang::comments::Token::getHTMLIdent(), clang::comments::Token::getHTMLQuotedString(), clang::comments::Token::getHTMLTagStartName(), clang::comments::Token::getKind(), clang::comments::Comment::getLocation(), clang::comments::Token::getLocation(), clang::SourceManager::getPresumedLineNumber(), clang::comments::Comment::getSourceRange(), clang::comments::tok::html_equals, clang::comments::tok::html_greater, clang::comments::tok::html_ident, clang::comments::tok::html_quoted_string, clang::comments::tok::html_slash_greater, clang::comments::tok::html_start_tag, clang::comments::Token::is(), and clang::comments::Token::isNot().
Referenced by parseParagraphOrBlockCommand().
InlineCommandComment * clang::comments::Parser::parseInlineCommand | ( | ) |
Definition at line 570 of file CommentParser.cpp.
References clang::comments::Sema::actOnInlineCommand(), clang::comments::tok::at_command, clang::comments::tok::backslash_command, clang::comments::Token::getCommandID(), clang::comments::CommandTraits::getCommandInfo(), clang::comments::Token::getEndLocation(), clang::comments::Token::getLocation(), clang::SourceLocation::getLocWithOffset(), clang::comments::Token::is(), clang::comments::CommandInfo::Name, clang::comments::CommandInfo::NumArgs, parseCommandArgs(), and clang::comments::TextTokenRetokenizer::putBackLeftoverTokens().
Referenced by parseParagraphOrBlockCommand().
BlockContentComment * clang::comments::Parser::parseParagraphOrBlockCommand | ( | ) |
Definition at line 714 of file CommentParser.cpp.
References clang::comments::Sema::actOnParagraphComment(), clang::comments::Sema::actOnText(), clang::comments::Sema::actOnUnknownCommand(), clang::comments::tok::at_command, clang::comments::tok::backslash_command, clang::comments::Sema::copyArray(), clang::comments::tok::eof, clang::comments::Token::getCommandID(), clang::comments::CommandTraits::getCommandInfo(), clang::comments::Token::getEndLocation(), clang::comments::CommandInfo::getID(), clang::comments::Token::getKind(), clang::comments::Token::getLocation(), clang::comments::Token::getText(), clang::comments::Token::getUnknownCommandName(), clang::comments::tok::html_end_tag, clang::comments::tok::html_equals, clang::comments::tok::html_greater, clang::comments::tok::html_ident, clang::comments::tok::html_quoted_string, clang::comments::tok::html_slash_greater, clang::comments::tok::html_start_tag, clang::comments::Token::is(), clang::comments::CommandInfo::IsBlockCommand, clang::comments::CommandInfo::IsInlineCommand, clang::comments::CommandInfo::IsUnknownCommand, clang::comments::CommandInfo::IsVerbatimBlockEndCommand, clang::isWhitespace(), clang::comments::CommandInfo::Name, clang::comments::tok::newline, parseBlockCommand(), parseHTMLEndTag(), parseHTMLStartTag(), parseInlineCommand(), clang::comments::tok::text, clang::comments::tok::unknown_command, clang::comments::tok::verbatim_block_begin, clang::comments::tok::verbatim_block_end, clang::comments::tok::verbatim_block_line, clang::comments::tok::verbatim_line_name, and clang::comments::tok::verbatim_line_text.
Referenced by parseBlockCommand(), and parseBlockContent().
void clang::comments::Parser::parseParamCommandArgs | ( | ParamCommandComment * | PC, |
TextTokenRetokenizer & | Retokenizer | ||
) |
Parse arguments for \param command.
Definition at line 394 of file CommentParser.cpp.
References clang::comments::Sema::actOnParamCommandDirectionArg(), clang::comments::Sema::actOnParamCommandParamNameArg(), clang::comments::Token::getEndLocation(), clang::comments::Token::getLocation(), clang::comments::Token::getText(), clang::comments::TextTokenRetokenizer::lexDelimitedSeq(), and clang::comments::TextTokenRetokenizer::lexWord().
Referenced by parseBlockCommand().
ArrayRef< Comment::Argument > clang::comments::Parser::parseParCommandArgs | ( | TextTokenRetokenizer & | Retokenizer, |
unsigned | NumArgs | ||
) |
Definition at line 455 of file CommentParser.cpp.
References clang::comments::Token::getEndLocation(), clang::comments::Token::getLocation(), clang::comments::Token::getText(), and clang::comments::TextTokenRetokenizer::lexParHeading().
Referenced by parseBlockCommand().
ArrayRef< Comment::Argument > clang::comments::Parser::parseThrowCommandArgs | ( | TextTokenRetokenizer & | Retokenizer, |
unsigned | NumArgs | ||
) |
Parse arguments for.
command | supported args are in form of class or template. |
Definition at line 438 of file CommentParser.cpp.
References clang::comments::Token::getEndLocation(), clang::comments::Token::getLocation(), clang::comments::Token::getText(), and clang::comments::TextTokenRetokenizer::lexType().
Referenced by parseBlockCommand().
void clang::comments::Parser::parseTParamCommandArgs | ( | TParamCommandComment * | TPC, |
TextTokenRetokenizer & | Retokenizer | ||
) |
Parse arguments for \tparam command.
Definition at line 412 of file CommentParser.cpp.
References clang::comments::Sema::actOnTParamCommandParamNameArg(), clang::comments::Token::getEndLocation(), clang::comments::Token::getLocation(), clang::comments::Token::getText(), and clang::comments::TextTokenRetokenizer::lexWord().
Referenced by parseBlockCommand().
VerbatimBlockComment * clang::comments::Parser::parseVerbatimBlock | ( | ) |
Definition at line 815 of file CommentParser.cpp.
References clang::comments::Sema::actOnVerbatimBlockFinish(), clang::comments::Sema::actOnVerbatimBlockLine(), clang::comments::Sema::actOnVerbatimBlockStart(), clang::comments::Sema::copyArray(), clang::comments::CommandTraits::getCommandInfo(), clang::comments::Token::getLocation(), clang::comments::Token::getVerbatimBlockID(), clang::comments::Token::getVerbatimBlockText(), clang::comments::Token::is(), clang::Line, clang::comments::CommandInfo::Name, clang::comments::tok::newline, clang::comments::tok::verbatim_block_begin, clang::comments::tok::verbatim_block_end, and clang::comments::tok::verbatim_block_line.
Referenced by parseBlockContent().
VerbatimLineComment * clang::comments::Parser::parseVerbatimLine | ( | ) |
Definition at line 861 of file CommentParser.cpp.
References clang::comments::Sema::actOnVerbatimLine(), clang::comments::Token::getEndLocation(), clang::comments::Token::getLocation(), clang::comments::Token::getVerbatimLineID(), clang::comments::Token::getVerbatimLineText(), clang::comments::Token::is(), Text, clang::comments::tok::verbatim_line_name, and clang::comments::tok::verbatim_line_text.
Referenced by parseBlockContent().
|
friend |
Definition at line 33 of file CommentParser.h.