clang-tools 22.0.0git
|
Optimize calls to std::string::find() and friends when the needle passed is a single character string literal. More...
#include <FasterStringFindCheck.h>
Public Member Functions | |
FasterStringFindCheck (StringRef Name, ClangTidyContext *Context) | |
bool | isLanguageVersionSupported (const LangOptions &LangOpts) const override |
void | registerMatchers (ast_matchers::MatchFinder *Finder) override |
void | check (const ast_matchers::MatchFinder::MatchResult &Result) override |
void | storeOptions (ClangTidyOptions::OptionMap &Opts) override |
Optimize calls to std::string::find() and friends when the needle passed is a single character string literal.
The character literal overload is more efficient.
For the user-facing documentation see: https://clang.llvm.org/extra/clang-tidy/checks/performance/faster-string-find.html
Definition at line 25 of file FasterStringFindCheck.h.
clang::tidy::performance::FasterStringFindCheck::FasterStringFindCheck | ( | StringRef | Name, |
ClangTidyContext * | Context ) |
Definition at line 54 of file FasterStringFindCheck.cpp.
|
override |
Definition at line 84 of file FasterStringFindCheck.cpp.
|
inlineoverride |
Definition at line 28 of file FasterStringFindCheck.h.
|
override |
Definition at line 66 of file FasterStringFindCheck.cpp.
|
override |
Definition at line 61 of file FasterStringFindCheck.cpp.
References clang::tidy::utils::options::serializeStringList().