Re: [PATCH] D7639: Add readability-redundant-void-arg check to clang-tidy

2015-10-18 Thread Richard via cfe-commits
LegalizeAdulthood updated this revision to Diff 37717. http://reviews.llvm.org/D7639 Files: clang-tidy/readability/CMakeLists.txt clang-tidy/readability/ReadabilityTidyModule.cpp clang-tidy/readability/RedundantVoidArgCheck.cpp clang-tidy/readability/RedundantVoidArgCheck.h test/clang-t

Re: [PATCH] D7639: Add readability-redundant-void-arg check to clang-tidy

2015-10-18 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. In http://reviews.llvm.org/D7639#266332, @Eugene.Zelenko wrote: > What is preventing to add this check to Clang-tidy? Just found another piece > of fresh C++ code in LLDB with (void) as argument list... To be honest, I don't know. This review had taken S

Re: [PATCH] D7639: Add readability-redundant-void-arg check to clang-tidy

2015-10-23 Thread Richard via cfe-commits
LegalizeAdulthood marked 17 inline comments as done. LegalizeAdulthood added a comment. Can we get this committed? I've addressed all comments. http://reviews.llvm.org/D7639 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.

Re: [PATCH] D10016: Refactor: Simplify boolean conditional return statements in lib/Frontend

2015-10-24 Thread Richard via cfe-commits
LegalizeAdulthood updated this revision to Diff 38309. LegalizeAdulthood added a comment. Update to latest http://reviews.llvm.org/D10016 Files: lib/Frontend/VerifyDiagnosticConsumer.cpp Index: lib/Frontend/VerifyDiagnosticConsumer.cpp

Re: [PATCH] D10016: Refactor: Simplify boolean conditional return statements in lib/Frontend

2015-10-24 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. This changeset needs review; I'm unsure of who to add as explicit reviewers. http://reviews.llvm.org/D10016 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe

Re: [PATCH] D10020: Refactor: Simplify boolean conditional return statements in lib/Serialization

2015-10-24 Thread Richard via cfe-commits
LegalizeAdulthood updated this revision to Diff 38310. LegalizeAdulthood added a comment. Update to latest http://reviews.llvm.org/D10020 Files: lib/Serialization/ASTReader.cpp lib/Serialization/ASTWriter.cpp Index: lib/Serialization/ASTWriter.cpp ==

Re: [PATCH] D10020: Refactor: Simplify boolean conditional return statements in lib/Serialization

2015-10-24 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. This changeset needs review, but I'm unsure of who to add as explicit reviewers. http://reviews.llvm.org/D10020 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo

Re: [PATCH] D10021: Refactor: Simplify boolean conditional return statements in lib/StaticAnalyzer/Checkers

2015-10-24 Thread Richard via cfe-commits
LegalizeAdulthood updated this revision to Diff 38311. LegalizeAdulthood added a comment. Update to latest. This changeset needs review; I am unsure who to add as specific reviewers. http://reviews.llvm.org/D10021 Files: lib/StaticAnalyzer/Checkers/BasicObjCFoundationChecks.cpp lib/StaticAn

Re: [PATCH] D10023: Refactor: Simplify boolean conditional return statements in lib/StaticAnalyzer/Frontend

2015-10-24 Thread Richard via cfe-commits
LegalizeAdulthood updated this revision to Diff 38312. LegalizeAdulthood added a comment. Update to latest. This changeset needs reveiw; I am unsure of who to add as specific reviewers. http://reviews.llvm.org/D10023 Files: lib/StaticAnalyzer/Frontend/CheckerRegistration.cpp Index: lib/Stati

Re: [PATCH] D10025: Refactor: Simplify boolean conditional return statements in clang-apply-replacements

2015-10-24 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. I do not have commit access; someone will need to commit this for me. http://reviews.llvm.org/D10025 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commit

Re: [PATCH] D10025: Refactor: Simplify boolean conditional return statements in clang-apply-replacements

2015-10-24 Thread Richard via cfe-commits
LegalizeAdulthood updated this revision to Diff 38313. LegalizeAdulthood added a comment. Update to latest http://reviews.llvm.org/D10025 Files: clang-apply-replacements/lib/Tooling/ApplyReplacements.cpp Index: clang-apply-replacements/lib/Tooling/ApplyReplacements.cpp ==

Re: [PATCH] D10024: Refactor: Simplify boolean conditional return statements in tools/libclang

2015-10-24 Thread Richard via cfe-commits
LegalizeAdulthood updated this revision to Diff 38315. LegalizeAdulthood marked 2 inline comments as done. LegalizeAdulthood added a comment. Update to latest. Update from comments. I don't have commit access. http://reviews.llvm.org/D10024 Files: tools/libclang/CIndex.cpp tools/libclang/In

Re: [PATCH] D10012: Refactor: Simplify boolean conditional return statements in lib/CodeGen

2015-10-24 Thread Richard via cfe-commits
LegalizeAdulthood updated this revision to Diff 38317. LegalizeAdulthood added a comment. Update to latest. I do not have commit access. http://reviews.llvm.org/D10012 Files: lib/CodeGen/BranchFolding.cpp lib/CodeGen/CodeGenPrepare.cpp lib/CodeGen/LiveDebugVariables.cpp lib/CodeGen/Mach

Re: [PATCH] D10011: Refactor: Simplify boolean conditional return statements in lib/Basic

2015-10-24 Thread Richard via cfe-commits
LegalizeAdulthood updated this revision to Diff 38318. LegalizeAdulthood added a comment. Update to latest. I do not have commit access. http://reviews.llvm.org/D10011 Files: lib/Basic/Targets.cpp Index: lib/Basic/Targets.cpp ==

Re: [PATCH] D10022: Refactor: Simplify boolean conditional return statements in lib/StaticAnalyzer/Core

2015-10-24 Thread Richard via cfe-commits
LegalizeAdulthood updated this revision to Diff 38319. LegalizeAdulthood added a comment. Update from latest http://reviews.llvm.org/D10022 Files: lib/StaticAnalyzer/Core/ExprEngineCallAndReturn.cpp lib/StaticAnalyzer/Core/SValBuilder.cpp lib/StaticAnalyzer/Core/SymbolManager.cpp Index:

Re: [PATCH] D10022: Refactor: Simplify boolean conditional return statements in lib/StaticAnalyzer/Core

2015-10-24 Thread Richard via cfe-commits
LegalizeAdulthood added inline comments. Comment at: lib/StaticAnalyzer/Core/ExprEngineCallAndReturn.cpp:692-693 @@ -691,4 +691,2 @@ CXXBasePaths Paths(false, false, false); - if (RD->lookupInBases( - [DeclName](const CXXBaseSpecifier *Specifier, CXXBasePath &Path)

Re: [PATCH] D10010: Refactor: Simplify boolean conditional return statements in lib/AST

2015-10-24 Thread Richard via cfe-commits
LegalizeAdulthood updated this revision to Diff 38321. LegalizeAdulthood added a comment. Update from latest. I do not have commit access. http://reviews.llvm.org/D10010 Files: lib/AST/ASTContext.cpp lib/AST/ASTDiagnostic.cpp lib/AST/Decl.cpp lib/AST/DeclCXX.cpp lib/AST/Expr.cpp lib

Re: [PATCH] D10017: Refactor: Simplify boolean conditional return statements in lib/Lex

2015-10-24 Thread Richard via cfe-commits
LegalizeAdulthood updated this revision to Diff 38322. LegalizeAdulthood added a comment. Update to latest. I do not have commit access. http://reviews.llvm.org/D10017 Files: lib/Lex/PPDirectives.cpp lib/Lex/PPMacroExpansion.cpp Index: lib/Lex/PPMacroExpansion.cpp =

Re: [PATCH] D10014: Refactor: Simplify boolean conditional return statements in lib/Edit

2015-10-24 Thread Richard via cfe-commits
LegalizeAdulthood updated this revision to Diff 38323. LegalizeAdulthood added a comment. Update from latest. I do not have commit access. http://reviews.llvm.org/D10014 Files: lib/Edit/RewriteObjCFoundationAPI.cpp Index: lib/Edit/RewriteObjCFoundationAPI.cpp

Re: [PATCH] D10014: Refactor: Simplify boolean conditional return statements in lib/Edit

2015-10-24 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. In http://reviews.llvm.org/D10014#178294, @calabrese wrote: > I like the idea of all of these changes (this change list and the others), > but just a suggestion -- it looks like when the branch of the original > condition returns false, as was the case in the

Re: [PATCH] D10019: Refactor: Simplify boolean conditional return statements in lib/Sema

2015-10-24 Thread Richard via cfe-commits
LegalizeAdulthood updated this revision to Diff 38324. LegalizeAdulthood added a comment. Update from latest. Update from comments. I do not have commit access. http://reviews.llvm.org/D10019 Files: lib/Sema/SemaChecking.cpp lib/Sema/SemaCodeComplete.cpp lib/Sema/SemaDecl.cpp lib/Sema/S

Re: [PATCH] D7639: Add readability-redundant-void-arg check to clang-tidy

2015-10-27 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. In http://reviews.llvm.org/D7639#275504, @sbenza wrote: > Just fyi, I am looking at this diff. It is very large with a lot of rounds of > comments and I didn't have the context. > I don't know if I should giving comments at this point of the change, but > her

Re: [PATCH] D7639: Add readability-redundant-void-arg check to clang-tidy

2015-10-27 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. I mean, look at this review. I created it on Feb 13th 2015. It's been getting ground through the review process for 8 months. Why can't we move forward? http://reviews.llvm.org/D7639 ___ cfe-commits mailing lis

Re: [PATCH] D16529: [clang-tidy] Add modernize-raw-string-literal check

2016-02-01 Thread Richard via cfe-commits
LegalizeAdulthood added inline comments. Comment at: clang-tidy/modernize/RawStringLiteralCheck.cpp:88 @@ +87,3 @@ +} + +bool containsDelimiter(StringRef Bytes, const std::string &Delimiter) { alexfh wrote: > aaron.ballman wrote: > > I think Alex's point is: why n

Re: [PATCH] D16308: clang-tidy Enhance readability-simplify-boolean-expr check to handle implicit conversions of integral types to bool and member pointers

2016-02-01 Thread Richard via cfe-commits
LegalizeAdulthood added inline comments. Comment at: clang-tidy/readability/SimplifyBooleanExprCheck.h:21-22 @@ -20,71 +20,4 @@ /// them to use the appropriate boolean expression directly. /// -/// Examples: -/// -/// ===

Re: [PATCH] D16526: Add hasRetValue narrowing matcher for returnStmt

2016-02-01 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. In http://reviews.llvm.org/D16526#334938, @aaron.ballman wrote: > I'm of two minds on this [...] I just need a thumbs up/down on this. Thumbs down, I discard the review. Thumbs up, you take the patch. Patch by Richard Thomson. http://reviews.llvm.org/D165

Re: [PATCH] D16308: clang-tidy Enhance readability-simplify-boolean-expr check to handle implicit conversions of integral types to bool and member pointers

2016-02-01 Thread Richard via cfe-commits
LegalizeAdulthood added inline comments. Comment at: clang-tidy/readability/SimplifyBooleanExprCheck.h:21-22 @@ -20,71 +20,4 @@ /// them to use the appropriate boolean expression directly. /// -/// Examples: -/// -/// ===

Re: [PATCH] D16308: clang-tidy Enhance readability-simplify-boolean-expr check to handle implicit conversions of integral types to bool and member pointers

2016-02-01 Thread Richard via cfe-commits
LegalizeAdulthood added inline comments. Comment at: clang-tidy/readability/SimplifyBooleanExprCheck.h:21-22 @@ -20,71 +20,4 @@ /// them to use the appropriate boolean expression directly. /// -/// Examples: -/// -/// ===

Re: [PATCH] D16308: clang-tidy Enhance readability-simplify-boolean-expr check to handle implicit conversions of integral types to bool and member pointers

2016-02-02 Thread Richard via cfe-commits
LegalizeAdulthood added inline comments. Comment at: clang-tidy/readability/SimplifyBooleanExprCheck.cpp:366 @@ +365,3 @@ + binaryOperator( + isExpansionInMainFile(), hasOperatorName(OperatorName), + hasLHS(allOf( aaron.ballman wrote: > Sorr

Re: [PATCH] D16308: clang-tidy Enhance readability-simplify-boolean-expr check to handle implicit conversions of integral types to bool and member pointers

2016-02-02 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. I do not have commit access. If someone could commit this for me, I would appreciate it. Patch by Richard Thomson. Thanks. http://reviews.llvm.org/D16308 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

Re: [PATCH] D16786: [Clang-tidy] Make modernize-redundant-void-arg working with included files

2016-02-03 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. I am already working on fixing this bug (isn't PR25894 already assigned to me?), but what's missing from this patch is an automated test that proves it works. In order to write such an automated test, I believe som

Re: [PATCH] D16700: [Clang-tidy] Make null pointer literals for fixes configurable for two checks

2016-02-03 Thread Richard via cfe-commits
LegalizeAdulthood added inline comments. Comment at: clang-tidy/readability/ImplicitBoolCastCheck.h:32 @@ -30,1 +31,3 @@ +Options.get("NullPointerLiteral", +Context->getLangOpts().CPlusPlus11 ? "nullptr" : "0")) {} void registerMatchers(ast_matchers::Mat

Re: [PATCH] D16794: [Clang-tidy] Make readability-simplify-boolean-expr working with included files

2016-02-03 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. Again, isn't this already assigned to me in the bug tracker? In general, my assumption in bug trackers is that if someone has assigned the bug to themselves, then they are working on it. Repository: rL LLVM http://reviews.llvm.org/D16794 ___

Re: [PATCH] D16794: [Clang-tidy] Make readability-simplify-boolean-expr working with included files

2016-02-03 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. In http://reviews.llvm.org/D16794#341552, @aaron.ballman wrote: > Missing a test case for this functionality. The isExpansionInMainFile() was > used to silence the diagnostic in macros, but it was pointed out during > review that this should be fixed and it se

Re: [PATCH] D16259: Add clang-tidy readability-redundant-control-flow check

2016-02-03 Thread Richard via cfe-commits
In article , Aaron Ballman writes: > On Wed, Feb 3, 2016 at 3:57 PM, Kim Gräsman wrote: > > On Mon, Feb 1, 2016 at 4:32 PM, Aaron Ballman > wrote: > >> > >> > >> Comment at: clang-tidy/readability/RedundantControlFlowCheck.cpp:60 > >> @@ +59,3 @@ > >> + if (const auto *R

Re: [PATCH] D16529: [clang-tidy] Add modernize-raw-string-literal check

2016-02-04 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. I agree it needs more testing. I think also my current approach to newlines is overly aggressive and will result in more raw string literals than people would prefer. It's really the Windows style path separators and regex ones that are not controversial tran

[PATCH] D16953: Enhance clang-tidy modernize-redundant-void-arg check to apply fixes to header files

2016-02-06 Thread Richard via cfe-commits
LegalizeAdulthood created this revision. LegalizeAdulthood added a reviewer: alexfh. LegalizeAdulthood added a subscriber: cfe-commits. Update `check_clang_tidy.py` to handle fixes applied to header files by adding `--header-filter` argument that: - Passes `-header-filter` down to `clang-tidy` -

Re: [PATCH] D16529: [clang-tidy] Add modernize-raw-string-literal check

2016-02-07 Thread Richard via cfe-commits
LegalizeAdulthood marked 5 inline comments as done. Comment at: clang-tidy/modernize/RawStringLiteralCheck.cpp:96 @@ +95,3 @@ + std::string Delimiter; + for (int Counter = 0; containsDelimiter(Bytes, Delimiter); ++Counter) { +Delimiter = (Counter == 0) ? "lit" : "lit" + std:

Re: [PATCH] D16529: [clang-tidy] Add modernize-raw-string-literal check

2016-02-07 Thread Richard via cfe-commits
LegalizeAdulthood updated this revision to Diff 47157. LegalizeAdulthood marked 2 inline comments as done. LegalizeAdulthood added a comment. Update from review comments. Added a bunch of test cases for non-printing characters, templates and macros. Removed string literals containing newline (`\

Re: [PATCH] D16308: clang-tidy Enhance readability-simplify-boolean-expr check to handle implicit conversions of integral types to bool and member pointers

2016-02-07 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. It's been almost a week. Is there some reason this hasn't been committed yet? http://reviews.llvm.org/D16308 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/c

Re: [PATCH] D16953: Enhance clang-tidy modernize-redundant-void-arg check to apply fixes to header files

2016-02-08 Thread Richard via cfe-commits
LegalizeAdulthood added inline comments. Comment at: test/clang-tidy/check_clang_tidy.py:122 @@ -40,2 +121,3 @@ parser.add_argument('-resource-dir') + parser.add_argument('--header-filter') parser.add_argument('input_file_name') alexfh wrote: > There's no n

Re: [PATCH] D16529: [clang-tidy] Add modernize-raw-string-literal check

2016-02-08 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. I wrote: > Repeated searching of the string for the literal delimiter could be avoided > by changing the routine to search for the delimiter. If present, it could > examine the characters following the literal to make the literal more unique > and then contin

Re: [PATCH] D16308: clang-tidy Enhance readability-simplify-boolean-expr check to handle implicit conversions of integral types to bool and member pointers

2016-02-09 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. In article , Aaron Ballman writes: > aaron.ballman added a comment. > > This is causing build bot failures: > > http://bb.pgr.jp/builders/cmake-clang-tools-x86_64-linux/builds/23351 > http://lab.llvm.org:8011/builders/clang-s390x-linux/builds/492 >

Re: [PATCH] D16308: clang-tidy Enhance readability-simplify-boolean-expr check to handle implicit conversions of integral types to bool and member pointers

2016-02-09 Thread Richard via cfe-commits
In article , Aaron Ballman writes: > aaron.ballman added a comment. > > This is causing build bot failures: > > http://bb.pgr.jp/builders/cmake-clang-tools-x86_64-linux/builds/23351 > http://lab.llvm.org:8011/builders/clang-s390x-linux/builds/492 > http://lab.llvm.org:8011/builders/clang-p

Re: [PATCH] D16953: Enhance clang-tidy modernize-redundant-void-arg check to apply fixes to header files

2016-02-09 Thread Richard via cfe-commits
LegalizeAdulthood marked an inline comment as done. Comment at: test/clang-tidy/check_clang_tidy.py:152 @@ -68,4 +151,3 @@ - has_check_fixes = input_text.find('CHECK-FIXES') >= 0 - has_check_messages = input_text.find('CHECK-MESSAGES') >= 0 + has_check_fixes, has_check_messag

Re: [PATCH] D16953: Enhance clang-tidy modernize-redundant-void-arg check to apply fixes to header files

2016-02-09 Thread Richard via cfe-commits
LegalizeAdulthood updated this revision to Diff 47319. LegalizeAdulthood added a comment. Update from review comments http://reviews.llvm.org/D16953 Files: clang-tidy/modernize/RedundantVoidArgCheck.cpp test/clang-tidy/check_clang_tidy.py test/clang-tidy/modernize-redundant-void-arg.cpp

Re: [PATCH] D16308: clang-tidy Enhance readability-simplify-boolean-expr check to handle implicit conversions of integral types to bool and member pointers

2016-02-09 Thread Richard via cfe-commits
LegalizeAdulthood updated this revision to Diff 47414. LegalizeAdulthood added a comment. Fixes StringRef problem that crashes tests in release builds only. http://reviews.llvm.org/D16308 Files: clang-tidy/readability/SimplifyBooleanExprCheck.cpp clang-tidy/readability/SimplifyBooleanExprCh

Re: [PATCH] D16308: clang-tidy Enhance readability-simplify-boolean-expr check to handle implicit conversions of integral types to bool and member pointers

2016-02-09 Thread Richard via cfe-commits
[Please reply *only* to the list and do not include my email directly in the To: or Cc: of your reply; otherwise I will not see your reply. Thanks.] In article , Richard via cfe-commits writes: > make check-all passes for me. I don't see what the problem is in the logs > eit

Re: [PATCH] D16310: new clang-tidy checker misc-long-cast

2016-02-09 Thread Richard via cfe-commits
LegalizeAdulthood added inline comments. Comment at: clang-tools-extra/trunk/clang-tidy/misc/MisplacedWideningCastCheck.cpp:21-23 @@ +20,5 @@ +void MisplacedWideningCastCheck::registerMatchers(MatchFinder *Finder) { + auto Calc = expr(anyOf(binaryOperator(anyOf( +

Re: [PATCH] D16310: new clang-tidy checker misc-long-cast

2016-02-10 Thread Richard via cfe-commits
In article , Daniel Marjamäki writes: > > You can get overflow with / and %. Consider: > > > > int i = INT_MIN / -1; // similar for % > > you are right, I did not think of that. > > imho overflow still seems unlikely for / and %. I thought the whole point was to flag instances where the

Re: [PATCH] D16953: Enhance clang-tidy modernize-redundant-void-arg check to apply fixes to header files

2016-02-11 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. Squeak? http://reviews.llvm.org/D16953 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D16529: [clang-tidy] Add modernize-raw-string-literal check

2016-02-11 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. Squeak? http://reviews.llvm.org/D16529 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D16308: clang-tidy Enhance readability-simplify-boolean-expr check to handle implicit conversions of integral types to bool and member pointers

2016-02-11 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. If someone could review the changes and commit this corrected version for me, that would be great. Patch by Richard Thomson. http://reviews.llvm.org/D16308 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

Re: [PATCH] D16529: [clang-tidy] Add modernize-raw-string-literal check

2016-02-12 Thread Richard via cfe-commits
LegalizeAdulthood added inline comments. Comment at: clang-tidy/modernize/RawStringLiteralCheck.cpp:97 @@ +96,3 @@ +} + +} // namespace alexfh wrote: > > I believe we agree on the following: ... > > Yes. > > > Where we seem to disagree is what algorithm should b

Re: [PATCH] D16529: [clang-tidy] Add modernize-raw-string-literal check

2016-02-13 Thread Richard via cfe-commits
LegalizeAdulthood updated this revision to Diff 47927. LegalizeAdulthood marked 4 inline comments as done. LegalizeAdulthood added a comment. Update from review comments. Avoid some string concatenation when delimiter is empty. http://reviews.llvm.org/D16529 Files: clang-tidy/modernize/CMakeL

Re: [PATCH] D16529: [clang-tidy] Add modernize-raw-string-literal check

2016-02-13 Thread Richard via cfe-commits
LegalizeAdulthood updated this revision to Diff 47928. LegalizeAdulthood added a comment. Add FIXME for non-ASCII string literals. Allow delimiter stem to be configured. Avoid some string concatenation. http://reviews.llvm.org/D16529 Files: clang-tidy/modernize/CMakeLists.txt clang-tidy/mod

Re: [PATCH] D16529: [clang-tidy] Add modernize-raw-string-literal check

2016-02-13 Thread Richard via cfe-commits
LegalizeAdulthood updated this revision to Diff 47929. LegalizeAdulthood marked an inline comment as done. LegalizeAdulthood added a comment. Add FIXME for macro argument test case. http://reviews.llvm.org/D16529 Files: clang-tidy/modernize/CMakeLists.txt clang-tidy/modernize/ModernizeTidyM

Re: [PATCH] D17244: [clang-tidy] readability-ternary-operator new check

2016-02-15 Thread Richard via cfe-commits
LegalizeAdulthood added inline comments. Comment at: docs/clang-tidy/checks/readability-ternary-operator.rst:10 @@ +9,3 @@ +And it gets transformed into:: + (condition ? expression0 : expression1); + Why add the parentheses around the entire statement? They seem

Re: [PATCH] D15332: new clang-tidy checker readability-non-const-parameter

2016-02-15 Thread Richard via cfe-commits
LegalizeAdulthood added a subscriber: LegalizeAdulthood. Comment at: docs/clang-tidy/checks/readability-non-const-parameter.rst:15 @@ +14,3 @@ + + // warning here; p should be const + char f1(char *p) { With pointers, there are always two layers of constness:

Re: [PATCH] D15332: new clang-tidy checker readability-non-const-parameter

2016-02-15 Thread Richard via cfe-commits
LegalizeAdulthood added inline comments. Comment at: test/clang-tidy/readability-non-const-parameter.cpp:3 @@ +2,3 @@ + +// Currently the checker only warns about pointer arguments. +// How hard is it to extend it to references? Certainly the confusion about what

Re: [PATCH] D15332: new clang-tidy checker readability-non-const-parameter

2016-02-17 Thread Richard via cfe-commits
LegalizeAdulthood added inline comments. Comment at: test/clang-tidy/readability-non-const-parameter.cpp:3 @@ +2,3 @@ + +// Currently the checker only warns about pointer arguments. +// danielmarjamaki wrote: > LegalizeAdulthood wrote: > > How hard is it to extend

Re: [PATCH] D16012: Carry raw string literal information through to the AST StringLiteral representation

2016-02-18 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. In http://reviews.llvm.org/D16012#351827, @rsmith wrote: > I'm definitely sympathetic to making `StringLiteralParser` expose information > [...] I was unaware of this class; so far I have only studied the classes appearing in the AST. I did notice that the

Re: [PATCH] D10013: Refactor: Simplify boolean conditional return statements in lib/Driver

2016-02-19 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. I do not have commit access, so someone else will need to commit this. Let me know if it needs rebasing. Patch by Richard Thomson. http://reviews.llvm.org/D10013 ___ cfe-commits mailing list cfe-commits@lists.ll

[PATCH] D17482: [clang-tidy] Allow tests to verify changes made to header files

2016-02-20 Thread Richard via cfe-commits
LegalizeAdulthood created this revision. LegalizeAdulthood added a reviewer: alexfh. LegalizeAdulthood added a subscriber: cfe-commits. This changeset improves check_clang_tidy.py to allow chnages made by a check to a header to be verified. A new argument `--header-filter` allows the test file t

Re: [PATCH] D17484: [clang-tidy] introduce modernize-deprecated-headers check

2016-02-20 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. Other than a few nits, LGTM. Comment at: clang-tidy/modernize/DeprecatedHeadersCheck.cpp:54 @@ +53,3 @@ +: Check(Check), LangOpts(LangOpts) { + CStyledHeaderToCxx["assert.h"] = "cassert"; + CStyledHeaderToCxx["float.h"] = "cfloat"; --

Re: [PATCH] D17484: [clang-tidy] introduce modernize-deprecated-headers check

2016-02-22 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. In http://reviews.llvm.org/D17484#358617, @alexfh wrote: > Thank you for this check! Mostly looks good, but there are a number of style > nits. > > The most important question to this check is that the standard doesn't > guarantee that the C++ headers declare

Re: [PATCH] D17446: ASTMatchers: add new statement/decl matchers

2016-02-22 Thread Richard via cfe-commits
LegalizeAdulthood added a subscriber: LegalizeAdulthood. Comment at: docs/LibASTMatchersReference.html:512 @@ +511,3 @@ +MatcherStmt>addrLabelExprMatcherAddrL

Re: [PATCH] D17811: [clang-tidy] Add check to detect dangling references in value handlers.

2016-03-30 Thread Richard via cfe-commits
LegalizeAdulthood added a subscriber: LegalizeAdulthood. LegalizeAdulthood added a comment. Can you add a synopsis of this new check to `docs/ReleaseNotes.rst` please? Repository: rL LLVM http://reviews.llvm.org/D17811 ___ cfe-commits mailing lis

Re: [PATCH] D18408: readability check for const params in declarations

2016-03-30 Thread Richard via cfe-commits
LegalizeAdulthood added a subscriber: LegalizeAdulthood. LegalizeAdulthood added a comment. You can submit the release notes changes in a new patch. Repository: rL LLVM http://reviews.llvm.org/D18408 ___ cfe-commits mailing list cfe-commits@lists

Re: [PATCH] D18265: [clang-tidy] New: checker misc-assign-operator-return

2016-03-30 Thread Richard via cfe-commits
LegalizeAdulthood added a subscriber: LegalizeAdulthood. LegalizeAdulthood added a comment. Please summarize this check in `docs/ReleaseNotes.rst`. There is a pending review that will stub this out automatically, but it hasn't been approved yet http://reviews.llvm.org/D18265 ___

Re: [PATCH] D18396: Clang-tidy:modernize-use-override. Fix for __declspec attributes and const=0 without spacse

2016-03-30 Thread Richard via cfe-commits
LegalizeAdulthood added a subscriber: LegalizeAdulthood. LegalizeAdulthood added a comment. Please summarize the improvements in `docs/ReleaseNotes.rst` in the clang tidy section. http://reviews.llvm.org/D18396 ___ cfe-commits mailing list cfe-comm

Re: [PATCH] D18136: boost-use-to-string check

2016-03-30 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. Please summarize this check in `docs/ReleaseNotes.rst` in the clang-tidy section. http://reviews.llvm.org/D18136 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listin

Re: [PATCH] D18408: readability check for const params in declarations

2016-03-30 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. Maybe you need to rebase first? I haven't used arc. Repository: rL LLVM http://reviews.llvm.org/D18408 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-

Re: [PATCH] D18457: [clang-tidy] Add a new checker to detect missing comma in initializer list.

2016-03-30 Thread Richard via cfe-commits
LegalizeAdulthood added a subscriber: LegalizeAdulthood. LegalizeAdulthood added a comment. Can you summarize this check in `docs/ReleaseNotes.rst` in the clang-tidy section, please? http://reviews.llvm.org/D18457 ___ cfe-commits mailing list cfe-c

Re: [PATCH] D18475: [clang-tidy] Add more detection rules for redundant c_str calls.

2016-03-30 Thread Richard via cfe-commits
LegalizeAdulthood added a subscriber: LegalizeAdulthood. LegalizeAdulthood added a comment. Can you summarize the improvements in `docs/ReleaseNotes.rst` please? http://reviews.llvm.org/D18475 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

Re: [PATCH] D18582: [Clang-tidy] Update release notes with list of checks added since 3.8

2016-03-30 Thread Richard via cfe-commits
LegalizeAdulthood added inline comments. Comment at: docs/ReleaseNotes.rst:143 @@ -71,3 +142,3 @@ Improvements to ``modularize`` ^^ The formatting here has been changed on trunk. Please rebase with a full file context so we can se

Re: [PATCH] D18584: Complete support for C++ Core Guidelines Type.6: Always initialize a member variable.

2016-03-30 Thread Richard via cfe-commits
LegalizeAdulthood added a subscriber: LegalizeAdulthood. LegalizeAdulthood added a comment. Can you summarize the improvements in `docs/ReleaseNotes.rst`, please? http://reviews.llvm.org/D18584 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

Re: [PATCH] D18509: clang-tidy: add_new_check.py stubs out release notes

2016-03-30 Thread Richard via cfe-commits
LegalizeAdulthood added inline comments. Comment at: clang-tidy/add_new_check.py:283 @@ +282,3 @@ + elif not clang_tidy_heading_found: +if line.startswith('^^'): + clang_tidy_heading_found = True Alex changed the f

Re: [PATCH] D17482: [clang-tidy] Allow tests to verify changes made to header files

2016-03-30 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. I'm sorry to be such a nag and I know you're busy, but This changeset has been held up for a month and a half. (6 weeks since originally posted in http://reviews.llvm.org/D16953) The change isn't that complicated and there haven't really been any comments

Re: [PATCH] D18608: note for top-level consts in function decls tidy

2016-03-30 Thread Richard via cfe-commits
LegalizeAdulthood added a subscriber: LegalizeAdulthood. Comment at: docs/ReleaseNotes.rst:153-154 @@ -152,2 +152,4 @@ + * `readability-avoid-const-params-in-decls +

Re: [PATCH] D18582: [Clang-tidy] Update release notes with list of checks added since 3.8

2016-03-30 Thread Richard via cfe-commits
LegalizeAdulthood added inline comments. Comment at: docs/ReleaseNotes.rst:143 @@ -71,3 +142,3 @@ Improvements to ``modularize`` ^^ LegalizeAdulthood wrote: > The formatting here has been changed on trunk. Please rebase with a full

Re: [PATCH] D18608: note for top-level consts in function decls tidy

2016-03-30 Thread Richard via cfe-commits
LegalizeAdulthood added inline comments. Comment at: docs/ReleaseNotes.rst:153-154 @@ -152,2 +152,4 @@ + * `readability-avoid-const-params-in-decls +

Re: [PATCH] D18509: clang-tidy: add_new_check.py stubs out release notes

2016-04-04 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. In http://reviews.llvm.org/D18509#388071, @hintonda wrote: > With this change, won't you need to update 2 different repos: clang and > extra? Is it possible to update both with a single Phabricator patch? This is updating the release notes in the extra repos

Re: [PATCH] D17482: [clang-tidy] Allow tests to verify changes made to header files

2016-04-04 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. As it stands currently, you can't commit a header with `CHECK-MESSAGES` and `CHECK-FIXES` lines and have them verified. That's the whole point of this changeset. Currently you have to do something very hacky in order to verify changes made to headers. http:

Re: [PATCH] D17482: [clang-tidy] Allow tests to verify changes made to header files

2016-04-04 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. In http://reviews.llvm.org/D17482#390237, @alexfh wrote: > My main concern is that this change makes the already complicated and > unobvious testing mechanism [...] The complexity and obtuseness of the existing testing mechanism is unrelated to this changese

Re: [clang-tools-extra] r264563 - clang-tidy: Fix broken buildbot

2016-04-05 Thread Richard via cfe-commits
In article , Alexander Kornienko writes: > > On Mon, Mar 28, 2016 at 6:15 AM, Richard Thomson via cfe-commits < > cfe-commits@lists.llvm.org> wrote: > > > Author: legalize > > Date: Sun Mar 27 23:15:41 2016 > > New Revision: 264563 > > > > URL: http://llvm.org/viewvc/llvm-project?rev=264563

Re: [PATCH] D18745: [clang-tidy] Adds modernize-use-bool-literals check.

2016-04-06 Thread Richard via cfe-commits
LegalizeAdulthood added a subscriber: LegalizeAdulthood. Comment at: docs/clang-tidy/checks/modernize-use-bool-literals.rst:17 @@ +16,1 @@ + std::ios_base::sync_with_stdio(false); \ No newline at end of file Please ensure the file ends with a newline. =

Re: [PATCH] D18783: [clang-tidy] add new checker for string literal with NUL character.

2016-04-06 Thread Richard via cfe-commits
LegalizeAdulthood added a subscriber: LegalizeAdulthood. LegalizeAdulthood added a comment. There are some APIs where a series of strings are passed as a single `char *` with NUL separators between the strings and the last string is indicated by two NUL characters in a row. For instance, see th

Re: [PATCH] D18852: [clang-tidy] fix a crash with -fdelayed-template-parsing in UnnecessaryValueParamCheck.

2016-04-06 Thread Richard via cfe-commits
LegalizeAdulthood added a subscriber: LegalizeAdulthood. LegalizeAdulthood added a comment. That we've had to fix this twice now tells me that our collective memory is forgetful :). We need to collect the community wisdom for `clang-tidy` gotchas somewhere in the docs... http://reviews.llvm.o

Re: [PATCH] D16535: [clang-tidy] Check to find unintended semicolons that changes the semantics.

2016-02-26 Thread Richard via cfe-commits
LegalizeAdulthood added a subscriber: LegalizeAdulthood. Comment at: docs/clang-tidy/checks/misc-suspicious-semicolon.rst:48-49 @@ +47,4 @@ + +while(readWhitespace()); + Token t = readNextToken(); + In this documentation, can we please format code so that

Re: [PATCH] D17482: [clang-tidy] Allow tests to verify changes made to header files

2016-03-01 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. Squeak http://reviews.llvm.org/D17482 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D16529: [clang-tidy] Add modernize-raw-string-literal check

2016-03-02 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. Squeak. This has been waiting on review for over two weeks http://reviews.llvm.org/D16529 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D10013: Refactor: Simplify boolean conditional return statements in lib/Driver

2016-03-02 Thread Richard via cfe-commits
LegalizeAdulthood abandoned this revision. LegalizeAdulthood added a comment. Discarding due to inaction by reviewers. http://reviews.llvm.org/D10013 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listi

Re: [PATCH] D7982: Add readability-duplicate-include check to clang-tidy

2016-03-02 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. I need to update from review comments and upload a new diff. http://reviews.llvm.org/D7982 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D16529: [clang-tidy] Add modernize-raw-string-literal check

2016-03-10 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. I do not have commit access, so I will need someone to commit this for me. Patch by Richard Thomson thanks. Comment at: clang-tidy/modernize/RawStringLiteralCheck.cpp:82 @@ +81,3 @@ +? std::string{R"lit()")lit"} +

Re: [PATCH] D17482: [clang-tidy] Allow tests to verify changes made to header files

2016-03-10 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. Another week without reviews... These changes were already split from a previous changeset without being reviewed properly. Squeak squeak squeak. http://reviews.llvm.org/D17482 ___ cfe-commits mailing list cfe-c

Re: [PATCH] D18136: boost-use-to-string check

2016-03-14 Thread Richard via cfe-commits
LegalizeAdulthood added a subscriber: LegalizeAdulthood. Comment at: clang-tidy/boost/BoostTidyModule.cpp:21 @@ -19,3 +20,3 @@ class ModernizeModule : public ClangTidyModule { public: This should be `BoostModule`, not `ModernizeModule`. Comme

Re: [PATCH] D18191: [clang-tidy] Add check for function parameters that are const& to builtin types

2016-03-18 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. In http://reviews.llvm.org/D18191#377686, @sdowney wrote: > In http://reviews.llvm.org/D18191#376471, @LegalizeAdulthood wrote: > > > There is utility in the definition of a function in saying that an argument > > is `const int i` instead of `int i`. The const

Re: [PATCH] D18263: [clang-tools-extra] Add release notes documentation

2016-03-18 Thread Richard via cfe-commits
LegalizeAdulthood updated this revision to Diff 51102. LegalizeAdulthood marked 2 inline comments as done. LegalizeAdulthood added a comment. Update from review comments. I do not have commit access. Patch by Richard Thomson http://reviews.llvm.org/D18263 Files: docs/ReleaseNotes.rst docs

Re: [PATCH] D17482: [clang-tidy] Allow tests to verify changes made to header files

2016-03-18 Thread Richard via cfe-commits
LegalizeAdulthood added a comment. test/clang-tidy/misc-unused-parameters.cpp currently does a hack to verify headers by committing the manually fixed header and diffing it: // RUN: echo "static void staticFunctionHeader(int i) {}" > %T/header.h // RUN: echo "static void staticFunctionHeader

  1   2   >