tra added inline comments.

================
Comment at: 
clang-tools-extra/clang-tidy/readability/IdentifierNamingCheck.cpp:388
         &NamingStyles) {
+  assert(D && D->getIdentifier() && !D->getName().empty() && !D->isImplicit() 
&&
+         "Decl must be an explicit identifier with a name.");
----------------
> Speaking of which, the result of getIdentifier() is never used, so the check 
> should probably be D->isIdentifier() both in this function and in the caller.

Scratch that. It's not worth the trouble, IMO. 
`D->getDeclName().isIdentifier()` is more verbose and does not buy us anything 
compared to `D->getIdentifier()` which expresses the intent well enough.



https://reviews.llvm.org/D52179



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

Reply via email to