Re: [PATCH] D12473: [clang-tidy] Add old style function check

2015-11-06 Thread Piotr Dziwinski via cfe-commits
piotrdz abandoned this revision. piotrdz added a comment. @alexfh: Ah, I forgot about this review. I will mark it as abandoned, because I have already started work on new check for localizing variables. It will have the wider scope that Eugene proposed originally, that is to move variable decla

[clang-tools-extra] r251244 - [clang-tidy] Another fix for failing buildbots regarding signedness of char

2015-10-25 Thread Piotr Dziwinski via cfe-commits
Author: piotrdz Date: Sun Oct 25 12:11:13 2015 New Revision: 251244 URL: http://llvm.org/viewvc/llvm-project?rev=251244&view=rev Log: [clang-tidy] Another fix for failing buildbots regarding signedness of char I totally forgot that char can be defined as unsigned on some platforms. Now I made exp

[clang-tools-extra] r251239 - [clang-tidy] Fix for build bots not liking #include

2015-10-25 Thread Piotr Dziwinski via cfe-commits
Author: piotrdz Date: Sun Oct 25 10:47:21 2015 New Revision: 251239 URL: http://llvm.org/viewvc/llvm-project?rev=251239&view=rev Log: [clang-tidy] Fix for build bots not liking #include Modified: clang-tools-extra/trunk/test/clang-tidy/readability-implicit-bool-cast-cxx98.cpp clang-tool

[clang-tools-extra] r251235 - [clang-tidy] Add check readability-implicit-bool-cast

2015-10-25 Thread Piotr Dziwinski via cfe-commits
Author: piotrdz Date: Sun Oct 25 10:31:25 2015 New Revision: 251235 URL: http://llvm.org/viewvc/llvm-project?rev=251235&view=rev Log: [clang-tidy] Add check readability-implicit-bool-cast Summary: This is another check that I ported to clang-tidy from colobot-lint tool. As previously discussed o

[clang-tools-extra] r251204 - Test commit

2015-10-24 Thread Piotr Dziwinski via cfe-commits
Author: piotrdz Date: Sat Oct 24 15:11:47 2015 New Revision: 251204 URL: http://llvm.org/viewvc/llvm-project?rev=251204&view=rev Log: Test commit Modified: clang-tools-extra/trunk/clang-tidy/readability/InconsistentDeclarationParameterNameCheck.cpp Modified: clang-tools-extra/trunk/clang-t

Re: [PATCH] D12462: [PATCH] [clang-tidy] Add inconsistent declaration parameter name check

2015-09-09 Thread Piotr Dziwinski via cfe-commits
piotrdz added a comment. \o/ Yay! Thanks! http://reviews.llvm.org/D12462 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D12462: [PATCH] [clang-tidy] Add inconsistent declaration parameter name check

2015-09-09 Thread Piotr Dziwinski via cfe-commits
piotrdz added a comment. @alexfh: here we go again. Any comments? Comment at: clang-tidy/readability/InconsistentDeclarationParameterNameCheck.cpp:289 @@ +288,3 @@ + +formatDifferingParamsDiagnostic(FormatParamsDiagnosticContext{ +InconsistentDeclaration.Declaration

Re: [PATCH] D12462: [PATCH] [clang-tidy] Add inconsistent declaration parameter name check

2015-09-09 Thread Piotr Dziwinski via cfe-commits
piotrdz updated this revision to Diff 34358. piotrdz marked 6 inline comments as done. piotrdz added a comment. Again, addressed all review issues. I hope this is the final version http://reviews.llvm.org/D12462 Files: clang-tidy/readability/CMakeLists.txt clang-tidy/readability/Inconsisten

Re: [PATCH] D12462: [PATCH] [clang-tidy] Add inconsistent declaration parameter name check

2015-09-08 Thread Piotr Dziwinski via cfe-commits
piotrdz added a comment. @alexfh: What do you think now? Are we getting nearer to making a commit? Comment at: clang-tidy/readability/InconsistentDeclarationParameterNameCheck.cpp:60 @@ +59,3 @@ + bool IsTemplateSpecialization; + DifferingParamsContainer DifferingParams; +};

Re: [PATCH] D12462: [PATCH] [clang-tidy] Add inconsistent declaration parameter name check

2015-09-08 Thread Piotr Dziwinski via cfe-commits
piotrdz updated this revision to Diff 34267. piotrdz marked 10 inline comments as done. piotrdz added a comment. I hope this is the final re-write of my code. In this version, I addressed most recent review comments, while also refactoring code to better handle template specializations and corre

Re: [PATCH] D12462: [PATCH] [clang-tidy] Add inconsistent declaration parameter name check

2015-09-05 Thread Piotr Dziwinski via cfe-commits
piotrdz added a comment. Now that I fixed all review issues, I think this version would be acceptable for commit. @alexfh: do you agree? There are of course two outstanding issues marked with TODO and FIXME comments, but these are areas of improvement. I would like to first discuss the best sol

Re: [PATCH] D12462: [PATCH] [clang-tidy] Add inconsistent declaration parameter name check

2015-09-05 Thread Piotr Dziwinski via cfe-commits
piotrdz updated this revision to Diff 34113. piotrdz marked 6 inline comments as done. piotrdz added a comment. I addressed all latest review issues. http://reviews.llvm.org/D12462 Files: clang-tidy/readability/CMakeLists.txt clang-tidy/readability/InconsistentDeclarationParameterNameCheck.

Re: [PATCH] D12462: [PATCH] [clang-tidy] Add inconsistent declaration parameter name check

2015-09-02 Thread Piotr Dziwinski via cfe-commits
piotrdz updated this revision to Diff 33879. piotrdz added a comment. In this third version I did the following: - fixed problems which I noticed with template specializations, - changed output diagnostics to be more detailed, covering multiple declarations - added FixIt hints to refactor inconsi

Re: [PATCH] D12462: [PATCH] [clang-tidy] Add inconsistent declaration parameter name check

2015-08-31 Thread Piotr Dziwinski via cfe-commits
piotrdz marked an inline comment as done. piotrdz added a comment. Now this issue with templates is a bit difficult for me. I tried everything that seems to have made sense, but I still get output like this: /work/clang-trunk/clang-tools-extra/test/clang-tidy/readability-inconsistent-declarat

Re: [PATCH] D12462: [PATCH] [clang-tidy] Add inconsistent declaration parameter name check

2015-08-31 Thread Piotr Dziwinski via cfe-commits
piotrdz updated this revision to Diff 33619. piotrdz marked 3 inline comments as done. piotrdz added a comment. Applied fixes for most issues found in review. http://reviews.llvm.org/D12462 Files: clang-tidy/readability/CMakeLists.txt clang-tidy/readability/InconsistentDeclarationParameterN

Re: [PATCH] D12462: [PATCH] [clang-tidy] Add inconsistent declaration parameter name check

2015-08-31 Thread Piotr Dziwinski via cfe-commits
piotrdz marked 7 inline comments as done. Comment at: clang-tidy/readability/InconsistentDeclarationParameterNameCheck.cpp:23 @@ +22,3 @@ + +struct CheckResult { + CheckResult(bool HasInconsistentParams, alexfh wrote: > Maybe use `llvm::Optional`? Or, if you don

Re: [PATCH] D12462: [PATCH] [clang-tidy] Add inconsistent declaration parameter name check

2015-08-31 Thread Piotr Dziwinski via cfe-commits
piotrdz added a comment. @alexfh: Thanks for reviewing my code. The amount of comments makes it pretty clear that it's my first contribution here :-). But no worries, I'll address each issue. > This check seems pretty similar to the check implemented in > clang-tidy/readability/NamedParameterC

Re: [PATCH] D12473: [clang-tidy] Add old style function check

2015-08-30 Thread Piotr Dziwinski via cfe-commits
unless somebody explains it in clearer terms. Best regards, Piotr Dziwinski On 2015-08-30 22:43, Aaron Ballman wrote: On Sun, Aug 30, 2015 at 4:39 PM, Piotr Dziwinski via cfe-commits wrote: piotrdz added a comment. @Eugene: I don't understand, what does declaring function with "void&

Re: [PATCH] D12473: [clang-tidy] Add old style function check

2015-08-30 Thread Piotr Dziwinski via cfe-commits
piotrdz added a comment. @Eugene: I don't understand, what does declaring function with "void" argument have in common with this review? I only check here variable declarations inside functions. Maybe you meant my other review for inconsistent declaration parameter names? If so, this is how it

[PATCH] D12473: [clang-tidy] Add old style function check

2015-08-30 Thread Piotr Dziwinski via cfe-commits
piotrdz created this revision. piotrdz added a subscriber: cfe-commits. This is another patch from my tool colobot-lint. This adds a new check misc-old-style-function, which checks for instances of functions written in legacy C style. As before, I hope I did everything according to LLVM style,

Re: [PATCH] D12462: [PATCH] [clang-tidy] Add inconsistent declaration parameter name check

2015-08-30 Thread Piotr Dziwinski via cfe-commits
piotrdz removed rL LLVM as the repository for this revision. piotrdz updated this revision to Diff 33527. piotrdz added a comment. I noticed a few things I should have done better: - use std::set instead of std::unordered_set (it doesn't seem to be used elsewhere) - move checking set of reported

[PATCH] D12462: [PATCH] [clang-tidy] Add inconsistent declaration parameter name check

2015-08-28 Thread Piotr Dziwinski via cfe-commits
piotrdz created this revision. piotrdz added a subscriber: cfe-commits. piotrdz set the repository for this revision to rL LLVM. This is first of series of patches, porting code from my project colobot-lint, as I mentioned recently in cfe-dev mailing list. This patch adds a new check in readabil