#include "clang/StaticAnalyzer/Checkers/BuiltinCheckerRegistration.h"
#include "clang/StaticAnalyzer/Core/BugReporter/BugType.h"
#include "clang/StaticAnalyzer/Core/BugReporter/CommonBugCategories.h"
#include "clang/StaticAnalyzer/Core/Checker.h"
#include "clang/StaticAnalyzer/Core/CheckerManager.h"
#include "clang/StaticAnalyzer/Core/PathSensitive/CallDescription.h"
#include "clang/StaticAnalyzer/Core/PathSensitive/CallEvent.h"
#include "clang/StaticAnalyzer/Core/PathSensitive/CheckerContext.h"
#include "clang/StaticAnalyzer/Core/PathSensitive/CheckerHelpers.h"
usingnamespaceclang;
usingnamespaceento;
namespace {
class MmapWriteExecChecker
: public Checker<check::ASTDecl<TranslationUnitDecl>, check::PreCall> { … };
}
void MmapWriteExecChecker::checkASTDecl(const TranslationUnitDecl *TU,
AnalysisManager &Mgr,
BugReporter &BR) const { … }
void MmapWriteExecChecker::checkPreCall(const CallEvent &Call,
CheckerContext &C) const { … }
void ento::registerMmapWriteExecChecker(CheckerManager &Mgr) { … }
bool ento::shouldRegisterMmapWriteExecChecker(const CheckerManager &) { … }