flx added inline comments.
================
Comment at: clang-tidy/performance/UnnecessaryValueParamCheck.cpp:41
@@ +40,3 @@
+ Function->parameters().begin();
+ if (Index >= Function->getNumParams()) {
+ return;
----------------
alexfh wrote:
> Please add a comment about when this happens (template parameter packs?
> C-style variadic functions?).
I"m not sure when this can happen. Should I remove it and we add it if we find
a case?
================
Comment at: clang-tidy/performance/UnnecessaryValueParamCheck.cpp:62
@@ +61,3 @@
+ "consider making it a const reference")
+ << Param->getName();
+ // Do not propose fixes in macros since we cannot place them correctly.
----------------
alexfh wrote:
> What if parameter doesn't have a name? Should we print an index ("parameter
> #n is copied ...").
Good point. Added test and index code.
http://reviews.llvm.org/D17491
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits