16 #ifndef LLVM_CLANG_TOOLS_EXTRA_CLANG_TIDY_ANDROID_CLOEXEC_H 17 #define LLVM_CLANG_TOOLS_EXTRA_CLANG_TIDY_ANDROID_CLOEXEC_H 19 #include "../ClangTidy.h" 37 ast_matchers::internal::Matcher<FunctionDecl> Function);
54 void insertMacroFlag(
const ast_matchers::MatchFinder::MatchResult &Result,
55 StringRef MacroFlag,
int ArgPos);
70 void replaceFunc(
const ast_matchers::MatchFinder::MatchResult &Result,
71 StringRef WarningMsg, StringRef FixMsg);
88 const char Mode,
const int ArgPos);
91 StringRef
getSpellingArg(
const ast_matchers::MatchFinder::MatchResult &Result,
105 #endif // LLVM_CLANG_TOOLS_EXTRA_CLANG_TIDY_ANDROID_CLOEXEC_H
void insertStringFlag(const ast_matchers::MatchFinder::MatchResult &Result, const char Mode, const int ArgPos)
Type3 is also to add a flag to the corresponding argument, but this time, the flag is some string and...
void insertMacroFlag(const ast_matchers::MatchFinder::MatchResult &Result, StringRef MacroFlag, int ArgPos)
Currently, we have three types of fixes.
static const char * FuncBindingStr
Binding name of the function call expression.
Base class for all clang-tidy checks.
void registerMatchersImpl(ast_matchers::MatchFinder *Finder, ast_matchers::internal::Matcher< FunctionDecl > Function)
void replaceFunc(const ast_matchers::MatchFinder::MatchResult &Result, StringRef WarningMsg, StringRef FixMsg)
Type2 is to replace the API to another function that has required the ability.
CloexecCheck(StringRef Name, ClangTidyContext *Context)
The base class for all close-on-exec checks in Android module.
===– Representation.cpp - ClangDoc Representation --------—*- C++ -*-===//
Every ClangTidyCheck reports errors through a DiagnosticsEngine provided by this context.
StringRef getSpellingArg(const ast_matchers::MatchFinder::MatchResult &Result, int N) const
Helper function to get the spelling of a particular argument.
static const char * FuncDeclBindingStr
Binding name of the FuncDecl of a function call.