alexfh added a comment.

I'm somewhat reluctant to add LLVM-specific checks to misc-. I would prefer 
either to split the LLVM-specific part to a separate check in llvm/ (which 
might derive from this check or somehow reuse the logic) or make the check 
configurable enough so that these checks can be enabled for LLVM in the config 
file.

================
Comment at: clang-tidy/misc/SuspiciousStringCompareCheck.cpp:119
@@ +118,3 @@
+      cxxMemberCallExpr(
+          callee(cxxMethodDecl(hasAnyName("::llvm::StringRef::compare",
+                                          "::llvm::StringRef::compare_lower",
----------------
This is inconsistent with the code above. I'd also use 
`ofClass(hasName("::llvm::StringRef")), hasAnyName("compare", ...)`.


http://reviews.llvm.org/D19577



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to