Re: [PATCH] D11946: Create clang-tidy module modernize. Add pass-by-value check.

2015-08-14 Thread Alexander Kornienko via cfe-commits
alexfh closed this revision. alexfh added a comment. Committed revision 245045. http://reviews.llvm.org/D11946 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D11946: Create clang-tidy module modernize. Add pass-by-value check.

2015-08-14 Thread Alexander Kornienko via cfe-commits
alexfh accepted this revision. alexfh added a comment. This revision is now accepted and ready to land. Now the tests pass. Thanks for fixing the IncludeInserter bug! http://reviews.llvm.org/D11946 ___ cfe-commits mailing list cfe-commits@lists.llvm

Re: [PATCH] D11946: Create clang-tidy module modernize. Add pass-by-value check.

2015-08-13 Thread Alexander Kornienko via cfe-commits
alexfh requested changes to this revision. alexfh added a comment. This revision now requires changes to proceed. I patched this in and the tests fail for me: clang/tools/extra/test/clang-tidy/modernize-pass-by-value.cpp:4:17: error: expected string not found in input // CHECK-FIXES: #includ

Re: [PATCH] D11946: Create clang-tidy module modernize. Add pass-by-value check.

2015-08-13 Thread Angel Garcia via cfe-commits
angelgarcia updated this revision to Diff 32061. angelgarcia added a comment. Remove StringSwitch. http://reviews.llvm.org/D11946 Files: clang-tidy/CMakeLists.txt clang-tidy/Makefile clang-tidy/modernize/CMakeLists.txt clang-tidy/modernize/Makefile clang-tidy/modernize/ModernizeTidyMo

Re: [PATCH] D11946: Create clang-tidy module modernize. Add pass-by-value check.

2015-08-13 Thread Alexander Kornienko via cfe-commits
alexfh added inline comments. Comment at: clang-tidy/modernize/PassByValueCheck.cpp:87 @@ +86,3 @@ +/// \brief Whether or not the parameter variable is referred only once in +/// the +/// given constructor. nit: clang-format doesn't properly reflow com

Re: [PATCH] D11946: Create clang-tidy module modernize. Add pass-by-value check.

2015-08-13 Thread Angel Garcia via cfe-commits
angelgarcia updated this revision to Diff 32059. angelgarcia added a comment. Remove StringSwitch. http://reviews.llvm.org/D11946 Files: clang-tidy/CMakeLists.txt clang-tidy/Makefile clang-tidy/modernize/CMakeLists.txt clang-tidy/modernize/Makefile clang-tidy/modernize/ModernizeTidyMo

Re: [PATCH] D11946: Create clang-tidy module modernize. Add pass-by-value check.

2015-08-13 Thread Alexander Kornienko via cfe-commits
alexfh added inline comments. Comment at: clang-tidy/modernize/PassByValueCheck.cpp:134 @@ +133,3 @@ +: ClangTidyCheck(Name, Context), + IncludeStyle(StringSwitch( + Options.get("IncludeStyle", "llvm")) Thinking a bit more of this, w

Re: [PATCH] D11946: Create clang-tidy module modernize. Add pass-by-value check.

2015-08-13 Thread Angel Garcia via cfe-commits
angelgarcia updated this revision to Diff 32055. angelgarcia marked 3 inline comments as done. angelgarcia added a comment. Make IncludeStyle constant, initialize it with StringSwitch. Fix indentation. http://reviews.llvm.org/D11946 Files: clang-tidy/CMakeLists.txt clang-tidy/Makefile cla

Re: [PATCH] D11946: Create clang-tidy module modernize. Add pass-by-value check.

2015-08-13 Thread Alexander Kornienko via cfe-commits
alexfh added inline comments. Comment at: clang-tidy/modernize/PassByValueCheck.cpp:131 @@ +130,3 @@ + : ClangTidyCheck(Name, Context) { +std::string IncludeStyleStr = Options.get("IncludeStyle", "llvm"); +if (IncludeStyleStr == "llvm") { alexfh wrote: >

Re: [PATCH] D11946: Create clang-tidy module modernize. Add pass-by-value check.

2015-08-13 Thread Alexander Kornienko via cfe-commits
alexfh accepted this revision. alexfh added a comment. This revision is now accepted and ready to land. Thanks for the updates. Looks good with a couple of nits. Comment at: clang-tidy/modernize/PassByValueCheck.cpp:83 @@ +82,3 @@ + public: +ExactlyOneUsageVisitor

Re: [PATCH] D11946: Create clang-tidy module modernize. Add pass-by-value check.

2015-08-13 Thread Angel Garcia via cfe-commits
angelgarcia updated this revision to Diff 32036. angelgarcia marked 4 inline comments as done. angelgarcia added a comment. Set IncludeStyle as an option. Fix comments. http://reviews.llvm.org/D11946 Files: clang-tidy/CMakeLists.txt clang-tidy/Makefile clang-tidy/modernize/CMakeLists.txt

Re: [PATCH] D11946: Create clang-tidy module modernize. Add pass-by-value check.

2015-08-12 Thread Alexander Kornienko via cfe-commits
alexfh added inline comments. Comment at: clang-tidy/modernize/PassByValueCheck.cpp:158 @@ +157,3 @@ + Compiler.getLangOpts(), + IncludeSorter::IS_LLVM)); + Compiler.getPreprocessor().addPPCallbacks(Inserter-

Re: [PATCH] D11946: Create clang-tidy module modernize. Add pass-by-value check.

2015-08-12 Thread Angel Garcia via cfe-commits
angelgarcia updated this revision to Diff 31948. angelgarcia marked 20 inline comments as done. angelgarcia added a comment. Fix tests and minor issues (auto, punctuation, etc). http://reviews.llvm.org/D11946 Files: clang-tidy/CMakeLists.txt clang-tidy/Makefile clang-tidy/modernize/CMakeL

Re: [PATCH] D11946: Create clang-tidy module modernize. Add pass-by-value check.

2015-08-12 Thread Alexander Kornienko via cfe-commits
alexfh added a comment. Something weird happened with the file names in this CL after the latest update, e.g. there are both `clang-tidy/CMakeLists.txt` and `CMakeLists.txt`. How exactly did you create the Differential revision and update it? Comment at: ModernizeTidyModule.cp

Re: [PATCH] D11946: Create clang-tidy module modernize. Add pass-by-value check.

2015-08-12 Thread Angel Garcia via cfe-commits
angelgarcia updated this revision to Diff 31911. angelgarcia added a comment. Run clang-format and minor fixes. http://reviews.llvm.org/D11946 Files: CMakeLists.txt Makefile ModernizeTidyModule.cpp PassByValueCheck.cpp PassByValueCheck.h clang-tidy/CMakeLists.txt clang-tidy/Makefi

Re: [PATCH] D11946: Create clang-tidy module modernize. Add pass-by-value check.

2015-08-12 Thread Manuel Klimek via cfe-commits
klimek added a subscriber: klimek. klimek added a comment. Minor nits; I'll want Alex to also take a look, as I had reviewed the original code before, so he probably has more insightful things to say :) Comment at: clang-tidy/modernize/ModernizeTidyModule.cpp:1 @@ +1,2 @@ +//==

[PATCH] D11946: Create clang-tidy module modernize. Add pass-by-value check.

2015-08-11 Thread Angel Garcia via cfe-commits
angelgarcia created this revision. angelgarcia added a reviewer: alexfh. angelgarcia added a subscriber: cfe-commits. angelgarcia changed the visibility of this Differential Revision from "Public (No Login Required)" to "All Users". This is the first step for migrating cppmodernize to clang-tidy.