[PATCH] D126134: [clang-tidy] Improve add_new_check.py to recognize more checks

2022-05-23 Thread Richard via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG89e663c4f83a: [clang-tidy] Improve add_new_check.py to recognize more checks (authored by LegalizeAdulthood). Repository: rG LLVM Github Monorepo

[PATCH] D126247: `readability-indentifier-naming` resolution order and examples

2022-05-23 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added inline comments. Comment at: clang-tools-extra/docs/clang-tidy/checks/readability-identifier-naming.rst:2742 double dValueDouble = 0.0; ULONGulValueUlong = 0; Phabricator says there is no context available. Did you genera

[PATCH] D134590: [clang-tidy] Fix a false positive in readability-simplify-boolean-expr

2022-09-24 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood accepted this revision. LegalizeAdulthood added a comment. This revision is now accepted and ready to land. LGTM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D134590/new/ https://reviews.llvm.org/D134590 _

[PATCH] D126495: [clang-tidy] Organize test docs into subdirectories by module (NFC)

2022-06-10 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. In D126495#3571511 , @njames93 wrote: > Search engines isn't really an issue, its more people who are using older > versions of llvm that try and go to the documentation which turns out is a > dead link. > Having said

[PATCH] D126495: [clang-tidy] Organize test docs into subdirectories by module (NFC)

2022-06-15 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. Ping. All review comments should be addressed in the latest diff. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D126495/new/ https://reviews.llvm.org/D126495 ___ cfe-commits mailing list cfe-commits@lists.ll

[PATCH] D126495: [clang-tidy] Organize test docs into subdirectories by module (NFC)

2022-06-16 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. In D126495#3588787 , @aaron.ballman wrote: > In D126495#3574115 , > @LegalizeAdulthood wrote: > >> In D126495#3571511 , @njames93 >>

[PATCH] D128072: [clang-tidy] Organize test files into subdirectories by module (NFC)

2022-06-17 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood created this revision. LegalizeAdulthood added reviewers: njames93, aaron.ballman. LegalizeAdulthood added a project: clang-tools-extra. Herald added subscribers: bzcheeseman, carlosgalvezp, abrachet, lebedev.ri, jdoerfert, arphaman, zzheng, kbarton, xazax.hun, nemanjai. Herald a

[PATCH] D128072: [clang-tidy] Organize test files into subdirectories by module (NFC)

2022-06-21 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. In D128072#3598634 , @aaron.ballman wrote: > This sounds like a sensible direction to me. I spot-checked the changes and > they all seem reasonable. Giving my LG, but please wait a bit before landing > in case someone

[PATCH] D128072: [clang-tidy] Organize test files into subdirectories by module (NFC)

2022-06-22 Thread Richard via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG89a1d03e2b37: [clang-tidy] Organize test files into subdirectories by module (NFC) (authored by LegalizeAdulthood). Changed prior to commit: https

[PATCH] D128157: [clang-tidy] cppcoreguidelines-virtual-class-destructor: Fix crash when "virtual" keyword is expanded from a macro

2022-06-22 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood requested changes to this revision. LegalizeAdulthood added a comment. This revision now requires changes to proceed. Please rebase this and folder your changes into `checkers/cppcoreguidelines/virtual-class-destructor.cpp` Repository: rG LLVM Github Monorepo CHANGES SINCE

[PATCH] D126880: [clang-tidy] Add cppcoreguidelines-avoid-const-or-ref-data-members check

2022-06-22 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood requested changes to this revision. LegalizeAdulthood added a comment. This revision now requires changes to proceed. Tests and docs have moved to subdirectories by module name. Please rebase onto HEAD and: - move `test/clang-tidy/checkers/cppcoreguidelines-avoid-const-or-ref-

[PATCH] D118996: [clang-tidy] Support C++14 in bugprone-signal-handler.

2022-06-22 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood requested changes to this revision. LegalizeAdulthood added a comment. This revision now requires changes to proceed. Clang-Tidy tests and docs have moved to module subdirectories. Please rebase this onto main:HEAD and: - fold your changes into the appropriate subdirs, strippin

[PATCH] D127293: [clang-tidy] Ignore other members in a union if any member of it is initialized in cppcoreguidelines-pro-type-member-init

2022-06-22 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood requested changes to this revision. LegalizeAdulthood added a comment. This revision now requires changes to proceed. Clang-Tidy tests and docs have moved to module subdirectories. Please rebase this onto `main:HEAD` and: - fold your changes into the appropriate subdirs, stripp

[PATCH] D127036: [clang-tidy] Warn about arrays in `bugprone-undefined-memory-manipulation`

2022-06-22 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood requested changes to this revision. LegalizeAdulthood added a comment. This revision now requires changes to proceed. Clang-Tidy tests and docs have moved to module subdirectories. Please rebase this onto `main:HEAD` and: - fold your changes into the appropriate subdirs, stripp

[PATCH] D124918: [clang-tidy] Add a new check for non-trivial unused variables.

2022-06-22 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood requested changes to this revision. LegalizeAdulthood added a comment. This revision now requires changes to proceed. Clang-Tidy tests and docs have moved to module subdirectories. Please rebase this onto `main:HEAD` and: - fold your changes into the appropriate subdirs, stripp

[PATCH] D119165: [clang-tidy] Add processing lambda captures at bugprone-use-after-move check

2022-06-22 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood requested changes to this revision. LegalizeAdulthood added a comment. This revision now requires changes to proceed. Clang-Tidy tests and docs have moved to module subdirectories. Please rebase this onto `main:HEAD` and: - fold your changes into the appropriate subdirs, stripp

[PATCH] D126735: [clang-tidy] Silence modernize-redundant-void-arg in the case of vexing parses

2022-06-22 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood requested changes to this revision. LegalizeAdulthood added a comment. This revision now requires changes to proceed. Clang-Tidy tests and docs have moved to module subdirectories. Please rebase this onto `main:HEAD` and: - fold your changes into the appropriate subdirs, stripp

[PATCH] D126097: [clang-tidy] Adds the NSDateFormatter checker to clang-tidy

2022-06-22 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood requested changes to this revision. LegalizeAdulthood added a comment. This revision now requires changes to proceed. Clang-Tidy tests and docs have moved to module subdirectories. Please rebase this onto `main:HEAD` and: - fold your changes into the appropriate subdirs, stripp

[PATCH] D118743: [clang-tidy] Add `modernize-use-inline-const-variables-in-headers` check

2022-06-22 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood requested changes to this revision. LegalizeAdulthood added a comment. This revision now requires changes to proceed. Clang-Tidy tests and docs have moved to module subdirectories. Please rebase this onto `main:HEAD` and: - fold your changes into the appropriate subdirs, stripp

[PATCH] D117593: [clang-tidy] Change google-explicit-constructor to ignore conversions and operators marked `explicit(false)`

2022-06-22 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood requested changes to this revision. LegalizeAdulthood added a comment. This revision now requires changes to proceed. Herald added a project: All. Clang-Tidy tests and docs have moved to module subdirectories. Please rebase this onto `main:HEAD` and: - fold your changes into th

[PATCH] D128402: [clang-tidy] Don't treat invalid branches as identical

2022-06-23 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added inline comments. Comment at: clang-tools-extra/docs/ReleaseNotes.rst:237 +- Fixed a false positive in :doc:`bugprone-branch-clone + ` when the branches + involve unknown expressions. This link is wrong, needs to use the `bugprone/` direc

[PATCH] D128401: [clang-tidy] Fixing a bug raising false alarms on static local variables in the Infinite Loop Checker

2022-06-23 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood requested changes to this revision. LegalizeAdulthood added a comment. This revision now requires changes to proceed. Clang-Tidy tests and docs have moved to module subdirectories. Please rebase this onto `main:HEAD` and: - fold your changes into the appropriate subdirs, stripp

[PATCH] D128372: Clang-Tidy Empty Check

2022-06-23 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood requested changes to this revision. LegalizeAdulthood added a comment. This revision now requires changes to proceed. Clang-Tidy tests and docs have moved to module subdirectories. Please rebase this onto `main:HEAD` and: - fold your changes into the appropriate subdirs, stripp

[PATCH] D128314: [Clang-tidy] Fixing a bug in clang-tidy infinite-loop checker

2022-06-23 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood requested changes to this revision. LegalizeAdulthood added a comment. This revision now requires changes to proceed. Clang-Tidy tests and docs have moved to module subdirectories. Please rebase this onto `main:HEAD` and: - fold your changes into the appropriate subdirs, stripp

[PATCH] D128157: [clang-tidy] cppcoreguidelines-virtual-class-destructor: Fix crash when "virtual" keyword is expanded from a macro

2022-06-23 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. In D128157#3605504 , @jspam wrote: > @LegalizeAdulthood Not sure what exactly you mean by "fold your changes into > `checkers/cppcoreguidelines/virtual-class-destructor.cpp`". The only rebase > conflict was in `Virtual

[PATCH] D126247: [clang-tidy][doc] Document readability-indentifier-naming resolution order and examples

2022-06-23 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood requested changes to this revision. LegalizeAdulthood added a comment. This revision now requires changes to proceed. Clang-Tidy tests and docs have moved to module subdirectories. Please rebase this onto `main:HEAD` and: - fold your changes into the appropriate subdirs, stripp

[PATCH] D116577: [clang-tidy] Added "boost-use-range-based-for-loop" check

2022-06-23 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood requested changes to this revision. LegalizeAdulthood added a comment. Herald added a project: All. Clang-Tidy tests and docs have moved to module subdirectories. Please rebase this onto `main:HEAD` and: - fold your changes into the appropriate subdirs, stripping the module pre

[PATCH] D56644: [clang-tidy] readability-container-size-empty handle std::string length()

2022-06-23 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood requested changes to this revision. LegalizeAdulthood added a comment. Herald added a project: All. Clang-Tidy tests and docs have moved to module subdirectories. Please rebase this onto `main:HEAD` and: - fold your changes into the appropriate subdirs, stripping the module pre

[PATCH] D128157: [clang-tidy] cppcoreguidelines-virtual-class-destructor: Fix crash when "virtual" keyword is expanded from a macro

2022-06-23 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood accepted this revision. LegalizeAdulthood added a comment. This revision is now accepted and ready to land. LGTM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128157/new/ https://reviews.llvm.org/D128157 _

[PATCH] D128402: [clang-tidy] Don't treat invalid branches as identical

2022-06-24 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added inline comments. Comment at: clang-tools-extra/docs/ReleaseNotes.rst:221-224 +- Fixed a crash in :doc:`performance-unnecessary-value-param + ` when the specialization + template has an unnecessary value parameter. Removed the fix for a template. + -

[PATCH] D128402: [clang-tidy] Don't treat invalid branches as identical

2022-06-24 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. OK, I've pushed the link fix and the sorting fix to main so if you rebase again, it should just show your changes to the release notes. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128402/new/ https://reviews.llvm.org/D128402 ___

[PATCH] D128401: [clang-tidy] Fixing a bug raising false alarms on static local variables in the Infinite Loop Checker

2022-06-24 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added inline comments. Comment at: clang-tools-extra/clang-tidy/bugprone/InfiniteLoopCheck.cpp:190 + +containsFunc |= (CanDecl == Func); +overlap |= Callees.contains(CanDecl); Personally I'm not a fan of using bitwise operators with bool

[PATCH] D128157: [clang-tidy] cppcoreguidelines-virtual-class-destructor: Fix crash when "virtual" keyword is expanded from a macro

2022-06-24 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. In D128157#3605829 , @jspam wrote: > I see :) Yes, looks like Git's rename detection did its job. > > Thanks for the review. Could you or someone else please merge this for me? > Author: Joachim Priesner I can submit,

[PATCH] D128157: [clang-tidy] cppcoreguidelines-virtual-class-destructor: Fix crash when "virtual" keyword is expanded from a macro

2022-06-24 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood requested changes to this revision. LegalizeAdulthood added a comment. This revision now requires changes to proceed. I get a test failure when I run with your change: -- Testing: 972 tests, 12 workers -- FAIL: Clang Tools :: clang-apply-replacements/basic.cpp (680 of 97

[PATCH] D128402: [clang-tidy] Don't treat invalid branches as identical

2022-06-25 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood requested changes to this revision. LegalizeAdulthood added a comment. This revision now requires changes to proceed. Rebase against main to get updated docs CHANGES SINCE LAST ACTION https://reviews.llvm.org/D128402/new/ https://reviews.llvm.org/D128402 ___

[PATCH] D128372: [Clang-Tidy] Empty Check

2022-06-25 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood requested changes to this revision. LegalizeAdulthood added inline comments. This revision now requires changes to proceed. Comment at: clang-tools-extra/test/clang-tidy/checkers/bugprone-standalone-empty.cpp:1 +// RUN: %check_clang_tidy %s bugprone-standalone-

[PATCH] D118996: [clang-tidy] Support C++14 in bugprone-signal-handler.

2022-06-25 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added inline comments. Comment at: clang-tools-extra/clang-tidy/bugprone/SignalHandlerCheck.cpp:282 +// These are all class names in ExprCXX.h without 'CXX' prefix. +#define CXXStmts \ + ArrayTypeTraitExpr,\ I'm not a fan of this macro, and we'

[PATCH] D128157: [clang-tidy] cppcoreguidelines-virtual-class-destructor: Fix crash when "virtual" keyword is expanded from a macro

2022-06-25 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood accepted this revision. LegalizeAdulthood added a comment. This revision is now accepted and ready to land. Well, it must have been unrelated to your change or some weird interaction on my machine because I rebased and ran `check-clang-extra` again and it passed this time. Re

[PATCH] D125622: [clang-tidy] Reject invalid enum initializers in C files

2022-05-27 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood updated this revision to Diff 432675. LegalizeAdulthood marked an inline comment as done. LegalizeAdulthood added a comment. - Update from review comments - Disallow operator, unless inside parentheses CHANGES SINCE LAST ACTION https://reviews.llvm.org/D125622/new/ https://r

[PATCH] D125622: [clang-tidy] Reject invalid enum initializers in C files

2022-05-27 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood marked 5 inline comments as done. LegalizeAdulthood added inline comments. Comment at: clang-tools-extra/clang-tidy/modernize/MacroToEnumCheck.cpp:324 { - IntegralLiteralExpressionMatcher Matcher(MacroTokens); - return Matcher.match(); + IntegralLiteralExpre

[PATCH] D125622: [clang-tidy] Reject invalid enum initializers in C files

2022-05-27 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood updated this revision to Diff 432676. LegalizeAdulthood added a comment. - Add C++ test case for acceptable `operator,` initializer CHANGES SINCE LAST ACTION https://reviews.llvm.org/D125622/new/ https://reviews.llvm.org/D125622 Files: clang-tools-extra/clang-tidy/moderni

[PATCH] D125622: [clang-tidy] Reject invalid enum initializers in C files

2022-06-01 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood marked 2 inline comments as done. LegalizeAdulthood added inline comments. Comment at: clang-tools-extra/test/clang-tidy/checkers/modernize-macro-to-enum.c:3-7 +// C requires enum values to fit into an int. +#define TOO_BIG1 1L +#define TOO_BIG2 1UL +#define TO

[PATCH] D125622: [clang-tidy] Reject invalid enum initializers in C files

2022-06-01 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood updated this revision to Diff 433648. LegalizeAdulthood added a comment. Update from review comments CHANGES SINCE LAST ACTION https://reviews.llvm.org/D125622/new/ https://reviews.llvm.org/D125622 Files: clang-tools-extra/clang-tidy/modernize/IntegralLiteralExpressionMat

[PATCH] D125622: [clang-tidy] Reject invalid enum initializers in C files

2022-06-01 Thread Richard via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGb418ef5cb90b: [clang-tidy] Reject invalid enum initializers in C files (authored by LegalizeAdulthood). Repository: rG LLVM Github Monorepo CHANG

[PATCH] D126495: [clang-tidy] Organize test docs into subdirectories by module (NFC)

2022-06-01 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. I know this is a rather huge diff, but the part that needs to be reviewed is the python script changes. I've rebuilt the HTML docs with sphinx and tested all the manually modified links to verify that they still go to the correct page. The existing Release No

[PATCH] D126495: [clang-tidy] Organize test docs into subdirectories by module (NFC)

2022-06-02 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. In D126495#3552887 , @njames93 wrote: > Can I ask what the motivation is for this change? https://discourse.llvm.org/t/clang-tidy-rfc-use-module-name-as-a-directory-for-organizing-files/62499 CHANGES SINCE LAST ACTION

[PATCH] D126495: [clang-tidy] Organize test docs into subdirectories by module (NFC)

2022-06-02 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. In D126495#3553183 , @LegalizeAdulthood wrote: > In D126495#3552887 , @njames93 > wrote: > >> Can I ask what the motivation is for this change? > > https://discourse.llvm.org/t

[PATCH] D126495: [clang-tidy] Organize test docs into subdirectories by module (NFC)

2022-06-08 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. Gentle ping CHANGES SINCE LAST ACTION https://reviews.llvm.org/D126495/new/ https://reviews.llvm.org/D126495 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/

[PATCH] D126495: [clang-tidy] Organize test docs into subdirectories by module (NFC)

2022-06-09 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. In D126495#3569029 , @njames93 wrote: > In D126495#3568998 , > @LegalizeAdulthood wrote: > >> Gentle ping > > My previous point about the links in the header files not being upd

[PATCH] D118711: [hack] Build a tree of preprocessing directives

2022-06-09 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. Herald added a project: All. I'm discarding this review, as it was just for comment purposes, until I have a proper implementation to discuss. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D118711/new/ https://reviews.llvm.org/D118711

[PATCH] D126495: [clang-tidy] Organize test docs into subdirectories by module (NFC)

2022-06-09 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. In D126495#3570767 , @aaron.ballman wrote: > In D126495#3569863 , > @LegalizeAdulthood wrote: > >> In D126495#3569029 , @njames93 >>

[PATCH] D72940: Add a support for clang tidy to import another configurations files from .clang-tidy

2023-03-22 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood resigned from this revision. LegalizeAdulthood added a comment. This revision now requires review to proceed. Herald added a reviewer: njames93. Herald added a subscriber: PiotrZSL. Herald added a project: All. No action taken, removing myself as a reviewer Repository: rG LLV

[PATCH] D130630: [clang-tidy] Add readability-nested-ifs check

2023-03-22 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. Herald added a subscriber: PiotrZSL. How does this check interact with macros that expand to `if` statements? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D130630/new/ https://reviews.llvm.org/D130630 ___

[PATCH] D130181: [clang-tidy] Add readability-use-early-exits check

2023-03-22 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. Herald added a subscriber: PiotrZSL. I'm not certain that the result of the transformation is more "readable"; is this check intended to aid conformance to a style guide? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.o

[PATCH] D146655: [clang-tidy] Ignore DISABLED_ in test suite name in google-avoid-underscore-in-googletest-name

2023-03-22 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added inline comments. Comment at: clang-tools-extra/test/clang-tidy/checkers/google/avoid-underscore-in-googletest-name.cpp:90 // Underscores are allowed to disable a test with the DISABLED_ prefix. -// https://github.com/google/googletest/blob/master/google

[PATCH] D133102: [clang-tidy] Extend simplify-boolean-expr check

2023-03-29 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. Herald added a subscriber: PiotrZSL. In D133102#3774151 , @alexfh wrote: > For example, LLVM coding standards recommends using early exits: > https://llvm.org/docs/CodingStandards.html#use-early-exits-and-continue-to-si

[PATCH] D128697: [clang-tidy] Add new check `bugprone-unhandled-exception-at-sto`

2023-03-29 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. Herald added a subscriber: PiotrZSL. In D128697#3638467 , @Sockke wrote: > In D128697#3619310 , > @LegalizeAdulthood wrote: > >> This whole check seems weird to me. I mean, alm

[PATCH] D126735: [clang-tidy] Silence modernize-redundant-void-arg in the case of vexing parses

2023-03-29 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added inline comments. Herald added a reviewer: njames93. Herald added a subscriber: PiotrZSL. Comment at: clang-tools-extra/test/clang-tidy/checkers/modernize/redundant-void-arg.cpp:596 + +// Explicitly specifying `(void)` is a way to sidestep -Wvexing-parse,

[PATCH] D28667: [clang-tidy] Don't modernize-raw-string-literal if replacement is longer.

2017-01-18 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. Don't do this without introducing an option to turn it off. https://reviews.llvm.org/D28667 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D28667: [clang-tidy] Don't modernize-raw-string-literal if replacement is longer.

2017-01-19 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. In https://reviews.llvm.org/D28667#649626, @LegalizeAdulthood wrote: > Don't do this without introducing an option to turn it off. To clarify my reasoning: You imposing your subjective idea of goodness on the code, i.e. style. Other people will have differen

[PATCH] D28667: [clang-tidy] Don't modernize-raw-string-literal if replacement is longer.

2017-01-19 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. In https://reviews.llvm.org/D28667#650586, @leanil wrote: > In https://reviews.llvm.org/D28667#650585, @LegalizeAdulthood wrote: > > > In https://reviews.llvm.org/D28667#649626, @LegalizeAdulthood wrote: > > > > > Don't do this without introducing an option to t

[PATCH] D117522: [clang-tidy] Add modernize-macro-to-enum check

2022-01-17 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood marked 13 inline comments as done. LegalizeAdulthood added inline comments. Comment at: clang-tools-extra/clang-tidy/modernize/MacroToEnumCheck.cpp:134 + +bool MacroToEnumCallbacks::isConsecutiveMacro(const MacroDirective *MD) const { + if (LastMacroLocation.is

[PATCH] D117522: [clang-tidy] Add modernize-macro-to-enum check

2022-01-17 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added inline comments. Comment at: clang-tools-extra/clang-tidy/modernize/MacroToEnumCheck.cpp:192-194 + if (LastFile != CurrentFile) { +LastFile = CurrentFile; +newEnum(); LegalizeAdulthood wrote: > njames93 wrote: > > This seems a str

[PATCH] D117522: [clang-tidy] Add modernize-macro-to-enum check

2022-01-17 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood updated this revision to Diff 400700. LegalizeAdulthood added a comment. Addresses most of the review comments, still need to: - Verify that include guards don't interfere with analysis of headers CHANGES SINCE LAST ACTION https://reviews.llvm.org/D117522/new/ https://revie

[PATCH] D117522: [clang-tidy] Add modernize-macro-to-enum check

2022-01-17 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added inline comments. Comment at: clang-tools-extra/clang-tidy/modernize/MacroToEnumCheck.cpp:182 + MD->getMacroInfo()->isUsedForHeaderGuard() || + MD->getMacroInfo()->isBuiltinMacro() || ConditionScope > 0) +return; LegalizeAdult

[PATCH] D117409: [clang-tidy] Move IncludeInserter into ClangTidyContext

2022-01-17 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added inline comments. Comment at: clang-tools-extra/clang-tidy/IncludeInserter.h:20 namespace tidy { -namespace utils { njames93 wrote: > LegalizeAdulthood wrote: > > njames93 wrote: > > > LegalizeAdulthood wrote: > > > > What's the guidance

[PATCH] D117535: [clang-tidy] Force LF newlines when writing files

2022-01-17 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood created this revision. LegalizeAdulthood added reviewers: alexfh, Quuxplusone, aaron.ballman. LegalizeAdulthood added a project: clang-tools-extra. Herald added subscribers: carlosgalvezp, xazax.hun. LegalizeAdulthood requested review of this revision. The recommendation on Windo

[PATCH] D116518: [ast-matchers] Add hasSubstatementSequence matcher

2022-01-17 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood abandoned this revision. LegalizeAdulthood added a comment. Based on discussion, I'm going to move this as a private matcher in the check where I intend to use it. Therefore, I'm abandoning this review. I look forward to seeing Yitzhak's generalized matcher `:)` CHANGES SINCE

[PATCH] D117535: [clang-tidy] Force LF newlines when writing files

2022-01-18 Thread Richard via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGe598913a4734: [clang-tidy] Force LF newlines when writing files (authored by LegalizeAdulthood). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D117535/new/ h

[PATCH] D116386: [clang-tidy] Narrow cppguidelines-macro-usage to actual constants

2022-01-18 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. Ping again. This change isn't that long or complicated and fixes a bug that results in false positives from this check. Please give it a review. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116386/new/ https://reviews.llvm.org/D116386 _

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

2022-01-18 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. 2nd. ping. Still waiting for a review on this check. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D7982/new/ https://reviews.llvm.org/D7982 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://li

[PATCH] D116386: [clang-tidy] Narrow cppguidelines-macro-usage to actual constants

2022-01-18 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. In D116386#3252351 , @carlosgalvezp wrote: > Would it be worth mentioning the change in the release notes? [...] Updating the documentation based on the discussion thread and the release notes are both good ideas, I'll

[PATCH] D116386: [clang-tidy] Narrow cppguidelines-macro-usage to actual constants

2022-01-18 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood updated this revision to Diff 401087. LegalizeAdulthood added a comment. - For function `isCapsOnly`: - Declare as static per LLVM style guide - Simplify boolean expression - Use `llvm::all_of` on container - Inline Function `isLiteralTokenSequence` as it is now simpler wit

[PATCH] D117522: [clang-tidy] Add modernize-macro-to-enum check

2022-01-19 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added inline comments. Comment at: clang-tools-extra/clang-tidy/modernize/MacroToEnumCheck.cpp:182 + MD->getMacroInfo()->isUsedForHeaderGuard() || + MD->getMacroInfo()->isBuiltinMacro() || ConditionScope > 0) +return; LegalizeAdult

[PATCH] D117522: [clang-tidy] Add modernize-macro-to-enum check

2022-01-19 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood updated this revision to Diff 401238. LegalizeAdulthood added a comment. - Handle macros inside header files with include guards - Track state per-file and push/pop that state as files are included CHANGES SINCE LAST ACTION https://reviews.llvm.org/D117522/new/ https://revie

[PATCH] D116386: [clang-tidy] Narrow cppguidelines-macro-usage to actual constants

2022-01-19 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood marked 2 inline comments as done. LegalizeAdulthood added inline comments. Comment at: clang-tools-extra/docs/clang-tidy/checks/cppcoreguidelines-macro-usage.rst:11 +`ES.31

[PATCH] D116386: [clang-tidy] Narrow cppguidelines-macro-usage to actual constants

2022-01-19 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood updated this revision to Diff 401242. LegalizeAdulthood marked an inline comment as done. LegalizeAdulthood added a comment. - Update from comments CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116386/new/ https://reviews.llvm.org/D116386 Files: clang-tools-extra/cl

[PATCH] D117522: [clang-tidy] Add modernize-macro-to-enum check

2022-01-19 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood updated this revision to Diff 401299. LegalizeAdulthood added a comment. - clang-format - prefer `llvm::any_of` over `std::any_of` CHANGES SINCE LAST ACTION https://reviews.llvm.org/D117522/new/ https://reviews.llvm.org/D117522 Files: clang-tools-extra/clang-tidy/moderniz

[PATCH] D116386: [clang-tidy] Narrow cppguidelines-macro-usage to actual constants

2022-01-19 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood marked 2 inline comments as done. LegalizeAdulthood added inline comments. Comment at: clang-tools-extra/clang-tidy/cppcoreguidelines/MacroUsageCheck.cpp:23 -namespace { - -bool isCapsOnly(StringRef Name) { - return std::all_of(Name.begin(), Name.end(), [](c

[PATCH] D116386: [clang-tidy] Narrow cppguidelines-macro-usage to actual constants

2022-01-19 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood marked 3 inline comments as done. LegalizeAdulthood added inline comments. Comment at: clang-tools-extra/docs/clang-tidy/checks/cppcoreguidelines-macro-usage.rst:11 +`ES.31

[PATCH] D116386: [clang-tidy] Narrow cppguidelines-macro-usage to actual constants

2022-01-19 Thread Richard via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. LegalizeAdulthood marked an inline comment as done. Closed by commit rGd83ecd77cc0f: [clang-tidy] Narrow cppguidelines-macro-usage to actual constants (authored by LegalizeAdulthood). Changed prior to commit: https://revi

[PATCH] D117522: [clang-tidy] Add modernize-macro-to-enum check

2022-01-19 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood updated this revision to Diff 401414. LegalizeAdulthood added a comment. - Tweak documentation, make sure sphinx runs without errors CHANGES SINCE LAST ACTION https://reviews.llvm.org/D117522/new/ https://reviews.llvm.org/D117522 Files: clang-tools-extra/clang-tidy/modern

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

2022-01-20 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. Ping. Still waiting for a review on this check. The implementation isn't particularly long or complicated, so it should not take much time to review. Thanks. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D7982/new/ https://reviews.llvm.org/D7982 ___

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

2022-01-20 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added inline comments. Comment at: clang-tools-extra/clang-tidy/readability/DuplicateIncludeCheck.cpp:64 +SrcMgr::CharacteristicKind FileType) { + if (!SM.isInMainFile(HashLoc)) { +return; carlosgalvezp wrote: > I'm not familiar with `

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

2022-01-20 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. > ! In D7982#325 , @carlosgalvezp > wrote: > I need to familiarize myself better with the `Loc` manipulation > code to be able to review the free-standing function but otherwise > looks reasonable. The "clang inter

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

2022-01-20 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood updated this revision to Diff 401837. LegalizeAdulthood added a comment. - Properly apply fixes to header files - Add tests for fixes in header files - Move function to static outside anonymous namespace - Improve documentation CHANGES SINCE LAST ACTION https://reviews.llvm.o

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

2022-01-20 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. @carlosgalvezp I believe I've addressed your comments now. Thanks for the review, it definitely improved this check. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D7982/new/ https://reviews.llvm.org/D7982 ___

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

2022-01-21 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added inline comments. Comment at: clang-tools-extra/test/clang-tidy/checkers/Inputs/readability-duplicate-include/readability-duplicate-include.h:1 +#if !defined(READABILITY_DUPLICATE_INCLUDE_H) +#define READABILITY_DUPLICATE_INCLUDE_H carlosg

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

2022-01-21 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. In D7982#3260403 , @carlosgalvezp wrote: > LGTM! Had some nits that can be fixed without review. I think you need to do "Accept Revision" in phabricator. It's in the "Add Action..." dropdown on the bottom of the review pa

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

2022-01-21 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood updated this revision to Diff 402071. LegalizeAdulthood added a comment. - Update from review comments CHANGES SINCE LAST ACTION https://reviews.llvm.org/D7982/new/ https://reviews.llvm.org/D7982 Files: clang-tools-extra/clang-tidy/readability/CMakeLists.txt clang-tools

[PATCH] D117939: [clang-tidy] Add more documentation about check development

2022-01-21 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood created this revision. LegalizeAdulthood added reviewers: alexfh, aaron.ballman, ymandel, njames93. LegalizeAdulthood added a project: clang-tools-extra. Herald added a subscriber: xazax.hun. LegalizeAdulthood requested review of this revision. - Mention pp-trace - CMake configur

[PATCH] D117939: [clang-tidy] Add more documentation about check development

2022-01-21 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood updated this revision to Diff 402153. LegalizeAdulthood added a comment. Spelling CHANGES SINCE LAST ACTION https://reviews.llvm.org/D117939/new/ https://reviews.llvm.org/D117939 Files: clang-tools-extra/docs/clang-tidy/Contributing.rst Index: clang-tools-extra/docs/clan

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

2022-01-22 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood updated this revision to Diff 402237. LegalizeAdulthood added a comment. Update from review comments CHANGES SINCE LAST ACTION https://reviews.llvm.org/D7982/new/ https://reviews.llvm.org/D7982 Files: clang-tools-extra/clang-tidy/readability/CMakeLists.txt clang-tools-e

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

2022-01-22 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added inline comments. Comment at: clang-tools-extra/test/clang-tidy/checkers/Inputs/readability-duplicate-include/readability-duplicate-include.h:1 +#if !defined(READABILITY_DUPLICATE_INCLUDE_H) +#define READABILITY_DUPLICATE_INCLUDE_H carlosg

[PATCH] D117939: [clang-tidy] Add more documentation about check development

2022-01-22 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood marked 7 inline comments as done. LegalizeAdulthood added a comment. In D117939#3263180 , @Eugene.Zelenko wrote: > It's also make sense to mention `isLanguageVersionSupported`. Good idea. CHANGES SINCE LAST ACTION https://reviews.l

[PATCH] D117939: [clang-tidy] Add more documentation about check development

2022-01-22 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood updated this revision to Diff 402238. LegalizeAdulthood added a comment. Update from review comments CHANGES SINCE LAST ACTION https://reviews.llvm.org/D117939/new/ https://reviews.llvm.org/D117939 Files: clang-tools-extra/docs/clang-tidy/Contributing.rst Index: clang-to

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

2022-01-22 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added a comment. In D7982#3263790 , @carlosgalvezp wrote: > Great patch, thanks!! Can you mark the patch as accepted in phabricator? Thanks CHANGES SINCE LAST ACTION https://reviews.llvm.org/D7982/new/ https://reviews.llvm.org/D7982

[PATCH] D117939: [clang-tidy] Add more documentation about check development

2022-01-22 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood added inline comments. Comment at: clang-tools-extra/docs/clang-tidy/Contributing.rst:295 +Reference `_ to understand +the relationship between the different matcher funtions. + Should b

[PATCH] D117939: [clang-tidy] Add more documentation about check development

2022-01-22 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood updated this revision to Diff 402283. LegalizeAdulthood added a comment. Update from review comments CHANGES SINCE LAST ACTION https://reviews.llvm.org/D117939/new/ https://reviews.llvm.org/D117939 Files: clang-tools-extra/docs/clang-tidy/Contributing.rst Index: clang-to

[PATCH] D117939: [clang-tidy] Add more documentation about check development

2022-01-22 Thread Richard via Phabricator via cfe-commits
LegalizeAdulthood updated this revision to Diff 402284. LegalizeAdulthood added a comment. Clarify ninja build example CHANGES SINCE LAST ACTION https://reviews.llvm.org/D117939/new/ https://reviews.llvm.org/D117939 Files: clang-tools-extra/docs/clang-tidy/Contributing.rst Index: clang-to

<    1   2   3   4   5   >