#include "CloexecCheck.h"
#include "../utils/ASTUtils.h"
#include "clang/AST/ASTContext.h"
#include "clang/ASTMatchers/ASTMatchFinder.h"
#include "clang/Lex/Lexer.h"
usingnamespaceclang::ast_matchers;
namespace clang::tidy::android {
namespace {
std::string buildFixMsgForStringFlag(const Expr *Arg, const SourceManager &SM,
const LangOptions &LangOpts, char Mode) { … }
}
const char *CloexecCheck::FuncDeclBindingStr = …;
const char *CloexecCheck::FuncBindingStr = …;
void CloexecCheck::registerMatchersImpl(
MatchFinder *Finder, internal::Matcher<FunctionDecl> Function) { … }
void CloexecCheck::insertMacroFlag(const MatchFinder::MatchResult &Result,
StringRef MacroFlag, int ArgPos) { … }
void CloexecCheck::replaceFunc(const MatchFinder::MatchResult &Result,
StringRef WarningMsg, StringRef FixMsg) { … }
void CloexecCheck::insertStringFlag(
const ast_matchers::MatchFinder::MatchResult &Result, const char Mode,
const int ArgPos) { … }
StringRef CloexecCheck::getSpellingArg(const MatchFinder::MatchResult &Result,
int N) const { … }
}