================
@@ -57,23 +57,24 @@ utils::UseRangesCheck::ReplacerMap
UseRangesCheck::getReplacerMap() const {
// Single range algorithms
AddStdToLLVM(llvm::makeIntrusiveRefCnt<StdToLLVMReplacer>(SingleSig),
- {"all_of", "any_of",
- "none_of", "for_each",
- "find", "find_if",
- "find_if_not", "fill",
- "count", "count_if",
- "copy", "copy_if",
- "transform", "replace",
- "remove_if", "stable_sort",
- "partition", "partition_point",
- "is_sorted", "min_element",
- "max_element", "binary_search",
- "lower_bound", "upper_bound",
- "unique", "uninitialized_copy"});
+ {"all_of", "any_of",
+ "none_of", "for_each",
+ "find", "find_if",
+ "find_if_not", "fill",
+ "count", "count_if",
+ "copy", "copy_if",
+ "transform", "replace",
+ "remove_if", "stable_sort",
+ "partition", "partition_point",
+ "is_sorted", "min_element",
+ "max_element", "binary_search",
+ "lower_bound", "upper_bound",
+ "unique", "uninitialized_copy",
+ "adjacent_find"});
// Two range algorithms
AddStdToLLVM(llvm::makeIntrusiveRefCnt<StdToLLVMReplacer>(TwoSig),
- {"equal", "mismatch", "includes"});
+ {"equal", "mismatch", "includes", "search"});
----------------
localspook wrote:
We [don't have exhaustive tests for all the algorithms
anyway](https://github.com/llvm/llvm-project/blob/56fb92ae643a0ba4def920c347f47e80934314b5/clang-tools-extra/test/clang-tidy/checkers/llvm/use-ranges.cpp#L74),
so I think we can go without, but cc @vbvictor as author of this check
https://github.com/llvm/llvm-project/pull/171666
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits