clang 10.0.0git

Public Member Functions | List of all members
clang::comments::BriefParser Class Reference

A very simple comment parser that extracts "a brief description". More...

`#include "clang/AST/CommentBriefParser.h"`

## Public Member Functions
| BriefParser (Lexer &L, const CommandTraits &Traits)
std::string | Parse ()
| Return the best "brief description" we can find. More...

## Detailed Description

A very simple comment parser that extracts "a brief description".

Due to a variety of comment styles, it considers the following as "a brief description", in order of priority:

- a \short command,
- the first paragraph,
- a \result or \return or \returns paragraph.

Definition at line 29 of file CommentBriefParser.h.

## Constructor & Destructor Documentation

## ◆ BriefParser()

clang::comments::BriefParser::BriefParser | ( | Lexer & | L,
|  | const CommandTraits & | Traits
| ) |  |

Definition at line 56 of file CommentBriefParser.cpp.

## Member Function Documentation

## ◆ Parse()

std::string clang::comments::BriefParser::Parse | ( |  | ) |

Return the best "brief description" we can find.

Definition at line 62 of file CommentBriefParser.cpp.

References clang::comments::tok::at_command, clang::comments::tok::backslash_command, clang::comments::tok::eof, clang::comments::Token::getCommandID(), clang::comments::CommandTraits::getCommandInfo(), clang::comments::Token::getText(), clang::comments::Token::is(), clang::comments::CommandInfo::IsBlockCommand, clang::comments::CommandInfo::IsBriefCommand, clang::comments::Token::isNot(), clang::comments::CommandInfo::IsReturnsCommand, clang::isWhitespace(), clang::comments::tok::newline, and clang::comments::tok::text.

The documentation for this class was generated from the following files:

- include/clang/AST/CommentBriefParser.h
- lib/AST/CommentBriefParser.cpp