|
clang 23.0.0git
|
#include "clang/ScalableStaticAnalysisFramework/Analyses/UnsafeBufferUsage/UnsafeBufferUsageExtractor.h"
Public Member Functions | |
| UnsafeBufferUsageTUSummaryExtractor (TUSummaryBuilder &Builder) | |
| EntityId | addEntity (EntityName EN) |
| std::unique_ptr< UnsafeBufferUsageEntitySummary > | extractEntitySummary (const Decl *Contributor, ASTContext &Ctx, llvm::Error &Error) |
| void | HandleTranslationUnit (ASTContext &Ctx) override |
| HandleTranslationUnit - This method is called when the ASTs for entire translation unit have been parsed. | |
| Public Member Functions inherited from clang::ssaf::TUSummaryExtractor | |
| TUSummaryExtractor (TUSummaryBuilder &Builder) | |
| Public Member Functions inherited from clang::ASTConsumer | |
| ASTConsumer ()=default | |
| virtual | ~ASTConsumer () |
| virtual void | Initialize (ASTContext &Context) |
| Initialize - This is called to initialize the consumer, providing the ASTContext. | |
| virtual bool | HandleTopLevelDecl (DeclGroupRef D) |
| HandleTopLevelDecl - Handle the specified top-level declaration. | |
| virtual void | HandleInlineFunctionDefinition (FunctionDecl *D) |
| This callback is invoked each time an inline (method or friend) function definition in a class is completed. | |
| virtual void | HandleInterestingDecl (DeclGroupRef D) |
| HandleInterestingDecl - Handle the specified interesting declaration. | |
| virtual void | HandleTagDeclDefinition (TagDecl *D) |
| HandleTagDeclDefinition - This callback is invoked each time a TagDecl (e.g. | |
| virtual void | HandleTagDeclRequiredDefinition (const TagDecl *D) |
| This callback is invoked the first time each TagDecl is required to be complete. | |
| virtual void | HandleCXXImplicitFunctionInstantiation (FunctionDecl *D) |
| Invoked when a function is implicitly instantiated. | |
| virtual void | HandleTopLevelDeclInObjCContainer (DeclGroupRef D) |
| Handle the specified top-level declaration that occurred inside and ObjC container. | |
| virtual void | HandleImplicitImportDecl (ImportDecl *D) |
| Handle an ImportDecl that was implicitly created due to an inclusion directive. | |
| virtual void | CompleteTentativeDefinition (VarDecl *D) |
| CompleteTentativeDefinition - Callback invoked at the end of a translation unit to notify the consumer that the given tentative definition should be completed. | |
| virtual void | CompleteExternalDeclaration (DeclaratorDecl *D) |
| CompleteExternalDeclaration - Callback invoked at the end of a translation unit to notify the consumer that the given external declaration should be completed. | |
| virtual void | AssignInheritanceModel (CXXRecordDecl *RD) |
| Callback invoked when an MSInheritanceAttr has been attached to a CXXRecordDecl. | |
| virtual void | HandleCXXStaticMemberVarInstantiation (VarDecl *D) |
| HandleCXXStaticMemberVarInstantiation - Tell the consumer that this. | |
| virtual void | HandleOpenACCRoutineReference (const FunctionDecl *FD, const OpenACCRoutineDecl *RD) |
| Callback to handle the end-of-translation unit attachment of OpenACC routine declaration information. | |
| virtual void | HandleVTable (CXXRecordDecl *RD) |
| Callback involved at the end of a translation unit to notify the consumer that a vtable for the given C++ class is required. | |
| virtual ASTMutationListener * | GetASTMutationListener () |
| If the consumer is interested in entities getting modified after their initial creation, it should return a pointer to an ASTMutationListener here. | |
| virtual ASTDeserializationListener * | GetASTDeserializationListener () |
| If the consumer is interested in entities being deserialized from AST files, it should return a pointer to a ASTDeserializationListener here. | |
| virtual void | PrintStats () |
| PrintStats - If desired, print any statistics. | |
| virtual bool | shouldSkipFunctionBody (Decl *D) |
This callback is called for each function if the Parser was initialized with SkipFunctionBodies set to true. | |
Static Public Member Functions | |
| static EntityPointerLevel | buildEntityPointerLevel (EntityId Entity, unsigned PointerLevel) |
Additional Inherited Members | |
| Protected Attributes inherited from clang::ssaf::TUSummaryExtractor | |
| TUSummaryBuilder & | SummaryBuilder |
Definition at line 20 of file UnsafeBufferUsageExtractor.h.
|
inline |
Definition at line 22 of file UnsafeBufferUsageExtractor.h.
References clang::ssaf::TUSummaryExtractor::TUSummaryExtractor().
|
inline |
Definition at line 30 of file UnsafeBufferUsageExtractor.h.
References clang::ssaf::TUSummaryExtractor::SummaryBuilder.
Referenced by HandleTranslationUnit().
|
inlinestatic |
Definition at line 25 of file UnsafeBufferUsageExtractor.h.
| std::unique_ptr< UnsafeBufferUsageEntitySummary > UnsafeBufferUsageTUSummaryExtractor::extractEntitySummary | ( | const Decl * | Contributor, |
| ASTContext & | Ctx, | ||
| llvm::Error & | Error ) |
Definition at line 298 of file UnsafeBufferUsageExtractor.cpp.
References clang::Error, and findUnsafePointersInContributor().
Referenced by HandleTranslationUnit().
|
overridevirtual |
HandleTranslationUnit - This method is called when the ASTs for entire translation unit have been parsed.
Reimplemented from clang::ASTConsumer.
Definition at line 310 of file UnsafeBufferUsageExtractor.cpp.
References addEntity(), clang::Error, extractEntitySummary(), clang::Decl::getDeclContext(), clang::ssaf::getEntityName(), clang::ASTContext::getTranslationUnitDecl(), clang::DeclContext::isFileContext(), clang::DeclContext::isNamespace(), clang::Success, and clang::ssaf::TUSummaryExtractor::SummaryBuilder.