================ @@ -96,6 +83,10 @@ void tests(std::string s, global_string s2) { // CHECK-MESSAGES: :[[@LINE-1]]:3: warning: use absl::StartsWith // CHECK-FIXES: {{^[[:space:]]*}}absl::StartsWith(s2, "a");{{$}} + sv.find("a") == 0; + // CHECK-MESSAGES: :[[@LINE-1]]:3: warning: use absl::StartsWith + // CHECK-FIXES: {{^[[:space:]]*}}absl::StartsWith(sv, "a");{{$}} + ---------------- PiotrZSL wrote:
Add test with rfind ```suggestion sv.rfind("a") != 0; // CHECK-MESSAGES: :[[@LINE-1]]:3: warning: use !absl::StartsWith // CHECK-FIXES: {{^[[:space:]]*}}!absl::StartsWith(sv, "a");{{$}} ``` https://github.com/llvm/llvm-project/pull/72283 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits