|
clang
5.0.0
|
Information about the declaration, useful to clients of FullComment. More...
#include "clang/AST/Comment.h"
Public Types | |
| enum | DeclKind { OtherKind, FunctionKind, ClassKind, VariableKind, NamespaceKind, TypedefKind, EnumKind } |
A simplified description of CommentDecl kind that should be good enough for documentation rendering purposes. More... | |
| enum | TemplateDeclKind { NotTemplate, Template, TemplateSpecialization, TemplatePartialSpecialization } |
What kind of template specialization CommentDecl is. More... | |
Public Member Functions | |
| void | fill () |
| DeclKind | getKind () const LLVM_READONLY |
| TemplateDeclKind | getTemplateKind () const LLVM_READONLY |
Public Attributes | |
| const Decl * | CommentDecl |
| Declaration the comment is actually attached to (in the source). More... | |
| const Decl * | CurrentDecl |
| CurrentDecl is the declaration with which the FullComment is associated. More... | |
| ArrayRef< const ParmVarDecl * > | ParamVars |
Parameters that can be referenced by \param if CommentDecl is something that we consider a "function". More... | |
| QualType | ReturnType |
Function return type if CommentDecl is something that we consider a "function". More... | |
| const TemplateParameterList * | TemplateParameters |
Template parameters that can be referenced by \tparam if CommentDecl is a template (IsTemplateDecl or IsTemplatePartialSpecialization is true). More... | |
| unsigned | IsFilled: 1 |
If false, only CommentDecl is valid. More... | |
| unsigned | Kind: 3 |
Simplified kind of CommentDecl, see DeclKind enum. More... | |
| unsigned | TemplateKind: 2 |
Is CommentDecl a template declaration. More... | |
| unsigned | IsObjCMethod: 1 |
Is CommentDecl an ObjCMethodDecl. More... | |
| unsigned | IsInstanceMethod: 1 |
Is CommentDecl a non-static member function of C++ class or instance method of ObjC class. More... | |
| unsigned | IsClassMethod: 1 |
Is CommentDecl a static member function of C++ class or class method of ObjC class. More... | |
Information about the declaration, useful to clients of FullComment.
A simplified description of CommentDecl kind that should be good enough for documentation rendering purposes.
| Enumerator | |
|---|---|
| OtherKind |
Everything else not explicitly mentioned below. |
| FunctionKind |
Something that we consider a "function":
|
| ClassKind |
Something that we consider a "class":
|
| VariableKind |
Something that we consider a "variable":
|
| NamespaceKind |
A C++ namespace. |
| TypedefKind |
A C++ typedef-name (a 'typedef' decl specifier or alias-declaration), see |
| EnumKind |
An enumeration or scoped enumeration. |
| void clang::comments::DeclInfo::fill | ( | ) |
Definition at line 190 of file Comment.cpp.
References ClassKind, CommentDecl, CurrentDecl, EnumKind, FunctionKind, clang::comments::getFunctionTypeLoc(), clang::Decl::getKind(), clang::DeclaratorDecl::getNumTemplateParameterLists(), clang::FunctionTypeLoc::getParams(), clang::FunctionTypeLoc::getReturnLoc(), clang::ObjCMethodDecl::getReturnType(), clang::FunctionDecl::getReturnType(), clang::FunctionTemplateDecl::getTemplatedDecl(), clang::TypeAliasTemplateDecl::getTemplatedDecl(), clang::DeclaratorDecl::getTemplateParameterList(), clang::TemplateDecl::getTemplateParameters(), clang::ClassTemplatePartialSpecializationDecl::getTemplateParameters(), clang::TypeLoc::getType(), clang::TypeSourceInfo::getTypeLoc(), clang::TypedefNameDecl::getTypeSourceInfo(), clang::TypeLoc::getUnqualifiedLoc(), IsClassMethod, IsFilled, clang::CXXMethodDecl::isInstance(), clang::ObjCMethodDecl::isInstanceMethod(), IsInstanceMethod, IsObjCMethod, NamespaceKind, clang::None, NotTemplate, OtherKind, clang::ObjCMethodDecl::parameters(), clang::FunctionDecl::parameters(), ParamVars, ReturnType, Template, TemplateKind, TemplateParameters, TemplatePartialSpecialization, TemplateSpecialization, TypedefKind, and VariableKind.
Referenced by clang::ASTContext::cloneFullComment(), clang::comments::FullComment::getDeclInfo(), and clang::comments::Sema::inspectThisDecl().
|
inline |
Definition at line 1087 of file Comment.h.
References Kind.
Referenced by clang::comments::Sema::isFunctionDecl(), clang::comments::Sema::isFunctionOrBlockPointerVarLikeDecl(), and clang::comments::Sema::isFunctionPointerVarDecl().
|
inline |
Definition at line 1091 of file Comment.h.
References TemplateKind.
Referenced by clang::comments::Sema::isTemplateOrSpecialization().
| const Decl* clang::comments::DeclInfo::CommentDecl |
Declaration the comment is actually attached to (in the source).
Should not be NULL.
Definition at line 989 of file Comment.h.
Referenced by clang::comments::Sema::checkDeprecatedCommand(), clang::comments::Sema::checkReturnsCommand(), clang::ASTContext::cloneFullComment(), fill(), clang::comments::FullComment::getDecl(), and clang::comments::Sema::setDecl().
| const Decl* clang::comments::DeclInfo::CurrentDecl |
CurrentDecl is the declaration with which the FullComment is associated.
It can be different from CommentDecl. It happens when we we decide that the comment originally attached to CommentDecl is fine for CurrentDecl too (for example, for a redeclaration or an overrider of CommentDecl).
The information in the DeclInfo corresponds to CurrentDecl.
Definition at line 999 of file Comment.h.
Referenced by fill(), clang::comments::Sema::isAnyFunctionDecl(), clang::comments::Sema::isClassOrStructDecl(), clang::comments::Sema::isClassTemplateDecl(), clang::comments::Sema::isFunctionOrBlockPointerVarLikeDecl(), clang::comments::Sema::isFunctionOrMethodVariadic(), clang::comments::Sema::isFunctionPointerVarDecl(), clang::comments::Sema::isFunctionTemplateDecl(), clang::comments::Sema::isObjCInterfaceDecl(), clang::comments::Sema::isObjCMethodDecl(), clang::comments::Sema::isObjCPropertyDecl(), clang::comments::Sema::isObjCProtocolDecl(), and clang::comments::Sema::isUnionDecl().
| unsigned clang::comments::DeclInfo::IsClassMethod |
| unsigned clang::comments::DeclInfo::IsFilled |
If false, only CommentDecl is valid.
Definition at line 1064 of file Comment.h.
Referenced by clang::ASTContext::cloneFullComment(), fill(), clang::comments::FullComment::getDeclInfo(), clang::comments::Sema::getParamVars(), clang::comments::Sema::isClassOrStructDecl(), clang::comments::Sema::isClassTemplateDecl(), clang::comments::Sema::isFunctionDecl(), clang::comments::Sema::isFunctionOrBlockPointerVarLikeDecl(), clang::comments::Sema::isFunctionPointerVarDecl(), clang::comments::Sema::isFunctionTemplateDecl(), clang::comments::Sema::isObjCInterfaceDecl(), clang::comments::Sema::isObjCPropertyDecl(), clang::comments::Sema::isObjCProtocolDecl(), clang::comments::Sema::isRecordLikeDecl(), clang::comments::Sema::isTemplateOrSpecialization(), clang::comments::Sema::isUnionDecl(), and clang::comments::Sema::setDecl().
| unsigned clang::comments::DeclInfo::IsInstanceMethod |
| unsigned clang::comments::DeclInfo::IsObjCMethod |
Is CommentDecl an ObjCMethodDecl.
Definition at line 1073 of file Comment.h.
Referenced by clang::comments::Sema::checkReturnsCommand(), and fill().
| unsigned clang::comments::DeclInfo::Kind |
| ArrayRef<const ParmVarDecl *> clang::comments::DeclInfo::ParamVars |
Parameters that can be referenced by \param if CommentDecl is something that we consider a "function".
Definition at line 1003 of file Comment.h.
Referenced by fill(), clang::comments::ParamCommandComment::getParamName(), and clang::comments::Sema::getParamVars().
| QualType clang::comments::DeclInfo::ReturnType |
Function return type if CommentDecl is something that we consider a "function".
Definition at line 1007 of file Comment.h.
Referenced by clang::comments::Sema::checkReturnsCommand(), and fill().
| unsigned clang::comments::DeclInfo::TemplateKind |
Is CommentDecl a template declaration.
Definition at line 1070 of file Comment.h.
Referenced by fill(), and getTemplateKind().
| const TemplateParameterList* clang::comments::DeclInfo::TemplateParameters |
Template parameters that can be referenced by \tparam if CommentDecl is a template (IsTemplateDecl or IsTemplatePartialSpecialization is true).
Definition at line 1012 of file Comment.h.
Referenced by clang::comments::Sema::actOnTParamCommandParamNameArg(), clang::ASTContext::cloneFullComment(), fill(), and clang::comments::TParamCommandComment::getParamName().
1.8.6