forked from OSchip/llvm-project
Apply clang-tidy's performance-unnecessary-value-param to clang-tidy.
No functionality change intended. llvm-svn: 298442
This commit is contained in:
parent
4e5a65fc83
commit
a079cdbeb8
|
@ -91,7 +91,7 @@ struct DenseMapInfo<
|
|||
return Val.first.getRawEncoding() + SecondHash(Val.second);
|
||||
}
|
||||
|
||||
static bool isEqual(ClassDefId LHS, ClassDefId RHS) {
|
||||
static bool isEqual(const ClassDefId &LHS, const ClassDefId &RHS) {
|
||||
if (RHS == getEmptyKey())
|
||||
return LHS == getEmptyKey();
|
||||
if (RHS == getTombstoneKey())
|
||||
|
|
|
@ -352,9 +352,9 @@ void UseAutoCheck::replaceIterators(const DeclStmt *D, ASTContext *Context) {
|
|||
<< FixItHint::CreateReplacement(Range, "auto");
|
||||
}
|
||||
|
||||
void UseAutoCheck::replaceExpr(const DeclStmt *D, ASTContext *Context,
|
||||
std::function<QualType(const Expr *)> GetType,
|
||||
StringRef Message) {
|
||||
void UseAutoCheck::replaceExpr(
|
||||
const DeclStmt *D, ASTContext *Context,
|
||||
llvm::function_ref<QualType(const Expr *)> GetType, StringRef Message) {
|
||||
const auto *FirstDecl = dyn_cast<VarDecl>(*D->decl_begin());
|
||||
// Ensure that there is at least one VarDecl within the DeclStmt.
|
||||
if (!FirstDecl)
|
||||
|
|
|
@ -26,7 +26,7 @@ public:
|
|||
private:
|
||||
void replaceIterators(const DeclStmt *D, ASTContext *Context);
|
||||
void replaceExpr(const DeclStmt *D, ASTContext *Context,
|
||||
std::function<QualType(const Expr *)> GetType,
|
||||
llvm::function_ref<QualType(const Expr *)> GetType,
|
||||
StringRef Message);
|
||||
|
||||
const bool RemoveStars;
|
||||
|
|
|
@ -49,7 +49,7 @@ struct DenseMapInfo<
|
|||
return Val.first.getRawEncoding() + SecondHash(Val.second);
|
||||
}
|
||||
|
||||
static bool isEqual(NamingCheckId LHS, NamingCheckId RHS) {
|
||||
static bool isEqual(const NamingCheckId &LHS, const NamingCheckId &RHS) {
|
||||
if (RHS == getEmptyKey())
|
||||
return LHS == getEmptyKey();
|
||||
if (RHS == getTombstoneKey())
|
||||
|
|
Loading…
Reference in New Issue