[PATCH] D52971: [clang-tidy] Customize FileCheck prefix in check_clang-tidy.py to support multiple prefixes

2018-10-07 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 168609. zinovy.nis added a comment. Removed "," from the list of allowed suffix characters. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D52971 Files: test/clang-tidy/check_clang_tidy.cpp test/clang-tidy/check_clang_tidy.py Index:

[PATCH] D52971: [clang-tidy] Customize FileCheck prefix in check_clang-tidy.py to support multiple prefixes

2018-10-07 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis marked an inline comment as done. zinovy.nis added inline comments. Comment at: test/clang-tidy/check_clang_tidy.py:94-95 +for check in args.check_suffix: + if not re.match('^[A-Z0-9\-,]+$', check): +sys.exit('Only A..Z, 0..9, "," and "-" are ' + +

[PATCH] D52971: [clang-tidy] Customize FileCheck prefix in check_clang-tidy.py to support multiple prefixes

2018-10-08 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. In https://reviews.llvm.org/D52971#1257702, @JonasToth wrote: > The change looks good in principle. I think it would make sense to migrate > one test already, to use the new capability and check if everything works as > expected. The current tests still run fine?

[PATCH] D52971: [clang-tidy] Customize FileCheck prefix in check_clang-tidy.py to support multiple prefixes

2018-10-08 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. In https://reviews.llvm.org/D52971#1257705, @alexfh wrote: > Looks good with a comment. It can break the compatibility. May be it worth to add an alias "-check-suffixes" for this option? Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D52971

[PATCH] D52971: [clang-tidy] Customize FileCheck prefix in check_clang-tidy.py to support multiple prefixes

2018-10-08 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 168690. zinovy.nis added a comment. - Fixed diagnostics; - Interchangeable alias introduced: `-check-suffixes` for `-check-suffix`. https://reviews.llvm.org/D52971 Files: test/clang-tidy/check_clang_tidy.cpp test/clang-tidy/check_clang_tidy.py

[PATCH] D52971: [clang-tidy] Customize FileCheck prefix in check_clang-tidy.py to support multiple prefixes

2018-10-12 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. In https://reviews.llvm.org/D52971#1262200, @ymandel wrote: > Hi, > > It looks like this change has disabled FileCheck for all clang-tidy lit tests > that don't use check-prefixes. So, they all trivially pass even if their > CHECK... lines are wrong. An easy repro

[PATCH] D53194: [clang-tidy] Fix check_clang_tidy.py trivially passing default CHECK

2018-10-12 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis created this revision. zinovy.nis added reviewers: ymandel, alexfh. zinovy.nis added a project: clang-tools-extra. Herald added subscribers: cfe-commits, xazax.hun. In https://reviews.llvm.org/D52971#1262200, @ymandel wrote: > Hi, > > It looks like this change has disabled FileCheck

[PATCH] D53194: [clang-tidy] Fix check_clang_tidy.py trivially passing default CHECK

2018-10-12 Thread Zinovy Nis via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL344343: [clang-tidy] Fix check_clang_tidy.py trivially passing default CHECK (authored by zinovy.nis, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit:

[PATCH] D45776: [clang-tidy] Customize FileCheck prefix in check_clang-tidy.py

2018-10-03 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. In https://reviews.llvm.org/D45776#1251256, @lebedev.ri wrote: > Did this intentionally omit the possibility to pass a group of prefixes, like > `FileCheck` supports? > Usefulness of this feature is somewhat penalized by this. I did not fully realize what do you

[PATCH] D52971: [clang-tidy] Customize FileCheck prefix in check_clang-tidy.py to support multiple prefixes

2018-10-08 Thread Zinovy Nis via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL344015: [clang-tidy] The patch extends the existing command line option -check-suffix (authored by zinovy.nis, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit:

[PATCH] D52771: [clang-tidy] Non-private member variables in classes (MISRA, CppCoreGuidelines, HICPP)

2018-10-11 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added inline comments. Comment at: test/clang-tidy/misc-non-private-member-variables-in-classes.cpp:1 +// RUN: %check_clang_tidy -check-suffix=NONPRIVATE %s misc-non-private-member-variables-in-classes %t +// RUN: %check_clang_tidy -check-suffix=NONPRIVATE %s

[PATCH] D52971: [clang-tidy] Customize FileCheck prefix in check_clang-tidy.py to support multiple prefixes

2018-10-07 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis created this revision. zinovy.nis added reviewers: lebedev.ri, alexfh. zinovy.nis added a project: clang-tools-extra. Herald added subscribers: cfe-commits, xazax.hun. The patch extends the existing command line option `-check_suffix` to accept multiple comma-separated prefixes. //

[PATCH] D45776: [clang-tidy] Customize FileCheck prefix in check_clang-tidy.py

2018-10-07 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. In https://reviews.llvm.org/D45776#1253944, @lebedev.ri wrote: > >> Did this intentionally omit the possibility to pass a group of prefixes, > >> like `FileCheck` supports? > >> Usefulness of this feature is somewhat penalized by this. Done. Please review this

[PATCH] D52971: [clang-tidy] Customize FileCheck prefix in check_clang-tidy.py to support multiple prefixes

2018-10-08 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. In https://reviews.llvm.org/D52971#1257702, @JonasToth wrote: > I think it would make sense to migrate one test already, to use the new > capability This change was inspired by Roman Lebedev (lebedev.ri), so we expect him to provide us with such a test soon ;-)

[PATCH] D59449: [clang-tidy] Integrate clang-tidy-diff.py machinery into run-clang-tidy.py

2019-04-03 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. @alexfh, do you still have any objections? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59449/new/ https://reviews.llvm.org/D59449 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D59734: [clang-tidy] Handle missing yaml module in run-clang-tidy.py

2019-03-27 Thread Zinovy Nis via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was automatically updated to reflect the committed changes. Closed by commit rL357114: [clang-tidy] Handle missing yaml module in run-clang-tidy.py (authored by zinovy.nis, committed by ). Herald

[PATCH] D59734: [clang-tidy] Handle missing yaml module in run-clang-tidy.py

2019-03-23 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis created this revision. zinovy.nis added reviewers: alexfh, bkramer, kuhar. zinovy.nis added a project: clang-tools-extra. Herald added subscribers: cfe-commits, xazax.hun. Herald added a reviewer: serge-sans-paille. Herald added a project: clang. The Yaml module is missing on some

[PATCH] D59734: [clang-tidy] Handle missing yaml module in run-clang-tidy.py

2019-03-23 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis marked an inline comment as done. zinovy.nis added inline comments. Comment at: test/clang-tidy/run-clang-tidy.cpp:1 +// RUN: %run_clang_tidy --help // RUN: rm -rf %t Just check that python doesn't complain on the script code and imported modules.

[PATCH] D59734: [clang-tidy] Handle missing yaml module in run-clang-tidy.py

2019-03-23 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 191992. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59734/new/ https://reviews.llvm.org/D59734 Files: clang-tidy/tool/run-clang-tidy.py test/clang-tidy/run-clang-tidy.cpp Index: test/clang-tidy/run-clang-tidy.cpp

[PATCH] D59449: [clang-tidy] Integrate clang-tidy-diff.py machinery into run-clang-tidy.py

2019-03-29 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. In D59449#1446839 , @thakis wrote: > Can we delete clang-tidy-diff.py with this? (Or delete most of its contents > and make it forward to this script?) I don't mind deleting clang-tidy-diff.py, but someone may want to use it

[PATCH] D59449: [clang-tidy] Integrate clang-tidy-diff.py machinery into run-clang-tidy.py

2019-03-31 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 193023. zinovy.nis added a comment. Herald added a subscriber: jdoerfert. Added a test. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59449/new/ https://reviews.llvm.org/D59449 Files: clang-tidy/tool/run-clang-tidy.py

[PATCH] D59449: [clang-tidy] Integrate clang-tidy-diff.py machinery into run-clang-tidy.py

2019-04-01 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. Gentle ping. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59449/new/ https://reviews.llvm.org/D59449 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D59449: [clang-tidy] Integrate clang-tidy-diff.py machinery into run-clang-tidy.py

2019-04-01 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. > Why not just use clang-tidy-diff.py? The clang-tidy-diff.py script has a > distinct and somewhat self-documenting name and a very specific purpose (find > clang-tidy regressions in a patch), while run-clang-tidy.py is more focused > on running over larger bodies

[PATCH] D59734: [clang-tidy] Handle missing yaml module in run-clang-tidy.py

2019-03-25 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 192137. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59734/new/ https://reviews.llvm.org/D59734 Files: clang-tidy/tool/run-clang-tidy.py test/clang-tidy/run-clang-tidy.cpp Index: test/clang-tidy/run-clang-tidy.cpp

[PATCH] D59734: [clang-tidy] Handle missing yaml module in run-clang-tidy.py

2019-03-25 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis marked an inline comment as done. zinovy.nis added inline comments. Comment at: clang-tidy/tool/run-clang-tidy.py:210 +help='Create a yaml file to store suggested fixes in, ' +'which can be applied with

[PATCH] D57662: [clang-tidy] Parallelize clang-tidy-diff.py

2019-03-06 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 189562. zinovy.nis added a comment. - honest '--export-fixes': multiple yamls are merged into the resulting one. - minor cosmetic fixes. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57662/new/ https://reviews.llvm.org/D57662 Files:

[PATCH] D57662: [clang-tidy] Parallelise clang-tidy-diff.py

2019-02-22 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis marked an inline comment as done. zinovy.nis added inline comments. Comment at: clang-tidy/tool/clang-tidy-diff.py:133 +if args.export_fixes: + print("error: -export-fixes and -j are mutually exclusive.") + sys.exit(1) alexfh wrote: >

[PATCH] D59449: [clang-tidy] Integrate clang-tidy-diff.py machinery into run-clang-tidy.py

2019-03-16 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis created this revision. zinovy.nis added reviewers: alexfh, bkramer. zinovy.nis added a project: clang-tools-extra. Herald added subscribers: cfe-commits, xazax.hun. Herald added a reviewer: serge-sans-paille. Herald added a project: clang. This patch adds a new `--diff[=2]` option to

[PATCH] D57662: [clang-tidy] Parallelize clang-tidy-diff.py

2019-03-08 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. Gentle ping. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57662/new/ https://reviews.llvm.org/D57662 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D59449: [clang-tidy] Integrate clang-tidy-diff.py machinery into run-clang-tidy.py

2019-03-19 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. In D59449#1435032 , @alexfh wrote: > How is this functionality different from the clang-tidy-diff.py script with > the -j option being added in the other patch? It's the same. Repository: rCTE Clang Tools Extra CHANGES

[PATCH] D57662: [clang-tidy] Parallelize clang-tidy-diff.py

2019-03-20 Thread Zinovy Nis via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rCTE356547: [clang-tidy] Parallelize clang-tidy-diff.py (authored by zinovy.nis, committed by ). Changed prior to commit: https://reviews.llvm.org/D57662?vs=189562=191474#toc Repository: rCTE Clang

[PATCH] D57662: [clang-tidy] Parallelize clang-tidy-diff.py

2019-03-19 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. One more gentle ping. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57662/new/ https://reviews.llvm.org/D57662 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D59449: [clang-tidy] Integrate clang-tidy-diff.py machinery into run-clang-tidy.py

2019-03-19 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. Any comments? Repository: rCTE Clang Tools Extra CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59449/new/ https://reviews.llvm.org/D59449 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D57662: [clang-tidy] Parallelise clang-tidy-diff.py

2019-02-12 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 186514. zinovy.nis added a comment. `-j` and `-export-fixes` were made mutually exclusive. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57662/new/ https://reviews.llvm.org/D57662 Files: clang-tidy/tool/clang-tidy-diff.py Index:

[PATCH] D57662: [clang-tidy] Parallelise clang-tidy-diff.py

2019-02-13 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. Any comments? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57662/new/ https://reviews.llvm.org/D57662 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D57662: [clang-tidy] Parallelise clang-tidy-diff.py

2019-02-14 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis marked an inline comment as done. zinovy.nis added inline comments. Comment at: clang-tidy/tool/clang-tidy-diff.py:76 +t = threading.Thread(target=tidy_caller, args=(task_queue, lock, timeout)) +t.daemon = True +t.start() JonasToth wrote:

[PATCH] D57662: [clang-tidy] Parallelise clang-tidy-diff.py

2019-02-10 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. Gentle ping. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57662/new/ https://reviews.llvm.org/D57662 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D57662: [clang-tidy] Parallelise clang-tidy-diff.py

2019-02-15 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis marked an inline comment as done. zinovy.nis added inline comments. Comment at: clang-tidy/tool/clang-tidy-diff.py:98 + parser.add_argument('-j', type=int, default=0, + help='number of tidy instances to be run in parallel.')

[PATCH] D57662: [clang-tidy] Parallelise clang-tidy-diff.py

2019-02-11 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. In D57662#1392509 , @MyDeveloperDay wrote: > Just a question.. If clang tidy is running with -fix in parallel, what stops > each clang-tidy invocation altering a common header at the same time? You are right. May be it

[PATCH] D57662: [clang-tidy] Parallelise clang-tidy-diff.py

2019-02-11 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. > I only say this because I think I might have seen it happen when I was > running `run-clang-tidy.py` over a large code base with a fairly aggressive > check/fixit, but frankly I was too new to LLVM to know it wasn't something I > might have done wrong. A bit

[PATCH] D57662: [clang-tidy] Parallelise clang-tidy-diff.py

2019-02-19 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 187421. zinovy.nis added a comment. - `-j` is `1` by default; - fixed minor remarks; CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57662/new/ https://reviews.llvm.org/D57662 Files: clang-tidy/tool/clang-tidy-diff.py Index:

[PATCH] D57662: [clang-tidy] Parallelise clang-tidy-diff.py

2019-02-03 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis created this revision. zinovy.nis added reviewers: alexfh, ehsan. zinovy.nis added a project: clang-tools-extra. Herald added subscribers: cfe-commits, xazax.hun. Herald added a reviewer: serge-sans-paille. Herald added a project: clang. This patch has 2 rationales: - large patches

[PATCH] D57662: [clang-tidy] Parallelise clang-tidy-diff.py

2019-02-04 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 185085. zinovy.nis added a comment. Fixed minor typos. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57662/new/ https://reviews.llvm.org/D57662 Files: clang-tidy/tool/clang-tidy-diff.py Index: clang-tidy/tool/clang-tidy-diff.py

[PATCH] D57662: [clang-tidy] Parallelise clang-tidy-diff.py

2019-02-04 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 185087. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57662/new/ https://reviews.llvm.org/D57662 Files: clang-tidy/tool/clang-tidy-diff.py Index: clang-tidy/tool/clang-tidy-diff.py

[PATCH] D65104: [clang-tidy] Add FixItHint for performance-noexcept-move-constructor

2019-08-04 Thread Zinovy Nis via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL367785: [clang-tidy] Add FixItHint for performance-noexcept-move-constructor (authored by zinovy.nis, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior

[PATCH] D65104: [clang-tidy] Add FixItHint for performance-noexcept-move-constructor

2019-07-24 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis marked an inline comment as done. zinovy.nis added inline comments. Comment at: clang-tidy/performance/NoexceptMoveConstructorCheck.cpp:57 + assert(Decl->getNumParams() > 0); + SourceLocation NoexceptLoc = Decl->getParamDecl(Decl->getNumParams() - 1) +

[PATCH] D65104: [clang-tidy] Add FixItHint for performance-noexcept-move-constructor

2019-07-24 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 211429. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65104/new/ https://reviews.llvm.org/D65104 Files: clang-tidy/performance/NoexceptMoveConstructorCheck.cpp test/clang-tidy/performance-noexcept-move-constructor-fix.cpp Index:

[PATCH] D65104: [clang-tidy] Add FixItHint for performance-noexcept-move-constructor

2019-07-24 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 211428. zinovy.nis added a comment. - Fixed tests. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65104/new/ https://reviews.llvm.org/D65104 Files: clang-tidy/performance/NoexceptMoveConstructorCheck.cpp

[PATCH] D65104: [clang-tidy] Add FixItHint for performance-noexcept-move-constructor

2019-07-22 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis created this revision. zinovy.nis added reviewers: alexfh, rsmith, aaron.ballman. Herald added subscribers: cfe-commits, xazax.hun. Herald added a project: clang. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D65104 Files:

[PATCH] D65104: [clang-tidy] Add FixItHint for performance-noexcept-move-constructor

2019-07-22 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 211147. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D65104/new/ https://reviews.llvm.org/D65104 Files: clang-tidy/performance/NoexceptMoveConstructorCheck.cpp test/clang-tidy/performance-noexcept-move-constructor-fix.cpp Index:

[PATCH] D69746: [analyzer] FixItHint: Apply and test hints with the Clang Tidy's script

2019-11-03 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added inline comments. Comment at: clang/lib/StaticAnalyzer/Frontend/AnalysisConsumer.cpp:152 + + if (llvm::Error Err = Repls.add(Repl)) +llvm_unreachable("An error occured during fix-it replacements"); Isn't `llvm_unreacheable`

[PATCH] D75021: [clang][analyzer] Enable core.builtin even with -no-default-checks

2020-02-23 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis created this revision. zinovy.nis added reviewers: abdulras, xazax.hun. zinovy.nis added a project: clang. Herald added subscribers: cfe-commits, Charusso, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, rnkovacs, szepet, baloghadamsoftware. It's required to properly handle

[PATCH] D74692: [clang-tidy] Make bugprone-use-after-move ignore std::move for const values

2020-02-25 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 246628. zinovy.nis added a comment. Warning on use after move is still generated. But there's also an additional note > std::move of the const expression has no effect; remove std::move() or make > the variable non-const CHANGES SINCE LAST ACTION

[PATCH] D74692: [clang-tidy][bugprone-use-after-move] Warn on std::move for consts

2020-03-03 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 247985. zinovy.nis added a comment. Typo fixed. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74692/new/ https://reviews.llvm.org/D74692 Files: clang-tools-extra/clang-tidy/bugprone/UseAfterMoveCheck.cpp

[PATCH] D74692: [clang-tidy][bugprone-use-after-move] Warn on std::move for consts

2020-03-03 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 247982. zinovy.nis added a comment. 1. Special handling for captured variables in lambdas, 2. messages texts were changed. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74692/new/ https://reviews.llvm.org/D74692 Files:

[PATCH] D74692: [clang-tidy][bugprone-use-after-move] Warn on std::move for consts

2020-03-06 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. Any further comments? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74692/new/ https://reviews.llvm.org/D74692 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D74692: [clang-tidy][bugprone-use-after-move] Warn on std::move for consts

2020-02-26 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis marked an inline comment as done. zinovy.nis added inline comments. Comment at: clang-tools-extra/test/clang-tidy/checkers/bugprone-use-after-move.cpp:329 // CHECK-NOTES: [[@LINE-3]]:7: note: move occurred here + // CHECK-NOTES: [[@LINE-6]]:7: note:

[PATCH] D74692: [clang-tidy] Make bugprone-use-after-move ignore std::move for const values

2020-02-17 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. In D74692#1879039 , @mboehme wrote: > Even if no move actually happens, the code is still wrong IMHO, it's not wrong, but it's inefficient. And will be reported by performance-move-const-arg. Repository: rG LLVM Github

[PATCH] D74692: [clang-tidy] Make bugprone-use-after-move ignore std::move for const values

2020-02-16 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 244878. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74692/new/ https://reviews.llvm.org/D74692 Files: clang-tools-extra/clang-tidy/bugprone/UseAfterMoveCheck.cpp clang-tools-extra/test/clang-tidy/checkers/bugprone-use-after-move.cpp

[PATCH] D74692: [clang-tidy] Make bugprone-use-after-move ignore std::move for const values

2020-02-16 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis created this revision. zinovy.nis added reviewers: mboehme, alexfh. zinovy.nis added a project: clang-tools-extra. Herald added subscribers: cfe-commits, mgehre, xazax.hun. Herald added a project: clang. std::move for const values is NO-OP, so it has no sense to report it in

[PATCH] D74692: [clang-tidy] Make bugprone-use-after-move ignore std::move for const values

2020-02-16 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 244876. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74692/new/ https://reviews.llvm.org/D74692 Files: clang-tools-extra/clang-tidy/bugprone/UseAfterMoveCheck.cpp clang-tools-extra/test/clang-tidy/checkers/bugprone-use-after-move.cpp

[PATCH] D74692: [clang-tidy] Make bugprone-use-after-move ignore std::move for const values

2020-02-20 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. In D74692#1884054 , @Quuxplusone wrote: > (I sent this to the mailing list, but I guess it doesn't show up here unless > I do it through Phab. Quoting myself—) > > I see your point about how users who care should always be

[PATCH] D57662: [clang-tidy] Parallelize clang-tidy-diff.py

2019-12-29 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. In D57662#1797607 , @derek wrote: > @zinovy.nis @alexfh @JonasToth @MyDeveloperDay > > I'd be happy to provide a patch. It would be nice, thanks! Repository: rCTE Clang Tools Extra CHANGES SINCE LAST ACTION

[PATCH] D74692: [clang-tidy][bugprone-use-after-move] Warn on std::move for consts

2020-03-11 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. I'm done, Aaron, Quuxplusone, do you have any comments? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74692/new/ https://reviews.llvm.org/D74692 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D74692: [clang-tidy][bugprone-use-after-move] Warn on std::move for consts

2020-03-07 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 248905. zinovy.nis marked 4 inline comments as done. zinovy.nis added a comment. Cosmetic and style fixes. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74692/new/ https://reviews.llvm.org/D74692 Files:

[PATCH] D74692: [clang-tidy][bugprone-use-after-move] Warn on std::move for consts

2020-03-07 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added inline comments. Comment at: clang-tools-extra/test/clang-tidy/checkers/bugprone-use-after-move.cpp:342 + // CHECK-NOTES: [[@LINE-5]]:20: note: variable 'a' implicitly captured const here }; } aaron.ballman wrote: > One more test

[PATCH] D74692: [clang-tidy][bugprone-use-after-move] Warn on std::move for consts

2020-03-14 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 250375. zinovy.nis added a comment. Removed top-level consts. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74692/new/ https://reviews.llvm.org/D74692 Files: clang-tools-extra/clang-tidy/bugprone/UseAfterMoveCheck.cpp

[PATCH] D74692: [clang-tidy][bugprone-use-after-move] Warn on std::move for consts

2020-03-15 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. In D74692#1923191 , @Quuxplusone wrote: > I still think this entire patch is misguided; there's no reason to make the > note for `const std::string s; std::move(s)` any longer than the note for > `int i; std::move(i)` or

[PATCH] D74692: [clang-tidy][bugprone-use-after-move] Warn on std::move for consts

2020-04-05 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 255128. zinovy.nis added a comment. Rebase over the current master. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74692/new/ https://reviews.llvm.org/D74692 Files: clang-tools-extra/clang-tidy/bugprone/UseAfterMoveCheck.cpp

[PATCH] D74692: [clang-tidy][bugprone-use-after-move] Warn on std::move for consts

2020-04-22 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. One more gentle ping) CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74692/new/ https://reviews.llvm.org/D74692 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D74692: [clang-tidy][bugprone-use-after-move] Warn on std::move for consts

2020-03-24 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. Gentle ping) CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74692/new/ https://reviews.llvm.org/D74692 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D74692: [clang-tidy][bugprone-use-after-move] Warn on std::move for consts

2020-03-08 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. In D74692#1911150 , @Quuxplusone wrote: > Anyway, I still don't see the point of this patch. It seems like you're just > duplicating the work of `performance-move-const-arg`. People who want to be > shown notes about

[PATCH] D74692: [clang-tidy][bugprone-use-after-move] Warn on std::move for consts

2020-03-08 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis marked 2 inline comments as done. zinovy.nis added inline comments. Comment at: clang-tools-extra/test/clang-tidy/checkers/bugprone-use-after-move.cpp:342 + // CHECK-NOTES: [[@LINE-5]]:20: note: variable 'a' implicitly captured const here }; }

[PATCH] D87627: [clang-tidy] Fix crash in modernize-use-noexcept on uninstantiated throw class

2020-09-15 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. Done. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87627/new/ https://reviews.llvm.org/D87627 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D87627: [clang-tidy] Fix crash in modernize-use-noexcept on uninstantiated throw class

2020-09-15 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 291971. zinovy.nis marked 2 inline comments as done. zinovy.nis added a comment. - Fixed the test. - Fixed clang-format issues. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87627/new/ https://reviews.llvm.org/D87627 Files:

[PATCH] D87627: [clang-tidy] Fix crash in modernize-use-noexcept on uninstantiated throw class

2020-09-15 Thread Zinovy Nis via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG96c6d012dfe2: [clang-tidy] Fix crash in modernize-use-noexcept on uninstantiated throw class (authored by zinovy.nis). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D87627: [clang-tidy] Fix crash in modernize-use-noexcept on uninstantiated throw class

2020-09-14 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis created this revision. zinovy.nis added reviewers: alexfh, rsmith. zinovy.nis added a project: clang-tools-extra. Herald added subscribers: cfe-commits, xazax.hun. Herald added a project: clang. zinovy.nis requested review of this revision. Bug:

[PATCH] D89194: [clang-tidy] Fix crash in readability-function-cognitive-complexity on weak refs

2020-10-10 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis created this revision. Herald added subscribers: cfe-commits, lebedev.ri, xazax.hun. Herald added a reviewer: lebedev.ri. Herald added a project: clang. zinovy.nis requested review of this revision. Assert fires on weak refs like static void dont_crash_on_weak()

[PATCH] D89194: [clang-tidy] Fix crash in readability-function-cognitive-complexity on weak refs

2020-10-11 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 297458. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D89194/new/ https://reviews.llvm.org/D89194 Files: clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp

[PATCH] D89194: [clang-tidy] Fix crash in readability-function-cognitive-complexity on weak refs

2020-10-11 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. In D89194#2323868 , @JonasToth wrote: > LGTM. > Short reminder to please use full context patches. Its not an issue right > now, but review sometimes just needs the context to understand the changes :) Sorry. Done.

[PATCH] D89194: [clang-tidy] Fix crash in readability-function-cognitive-complexity on weak refs

2020-10-11 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 297462. zinovy.nis added a comment. - Updated docs on the matcher. - Register the new matcher. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D89194/new/ https://reviews.llvm.org/D89194 Files:

[PATCH] D89194: [clang-tidy] Fix crash in readability-function-cognitive-complexity on weak refs

2020-10-11 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. Done. Any other comments/ideas? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D89194/new/ https://reviews.llvm.org/D89194 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D89194: [clang-tidy] Fix crash in readability-function-cognitive-complexity on weak refs

2020-10-11 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 297463. zinovy.nis added a comment. Full diff. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D89194/new/ https://reviews.llvm.org/D89194 Files: clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp

[PATCH] D89194: [clang-tidy] Fix crash in readability-function-cognitive-complexity on weak refs

2020-10-11 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 297468. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D89194/new/ https://reviews.llvm.org/D89194 Files: clang-tools-extra/clang-tidy/readability/FunctionCognitiveComplexityCheck.cpp

[PATCH] D89194: [clang-tidy] Fix crash in readability-function-cognitive-complexity on weak refs

2020-10-11 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. In D89194#2323917 , @JonasToth wrote: > I am fine now, thank you! Thanks! Is this patch ready for landing? Or should I wait for a few more approvals? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D89194/new/

[PATCH] D89194: [clang-tidy] Fix crash in readability-function-cognitive-complexity on weak refs

2020-10-11 Thread Zinovy Nis via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG32d565b4618d: [clang-tidy] Fix crash in readability-function-cognitive-complexity on weak refs (authored by zinovy.nis). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D80536: [clang-tidy][modernize-loop-convert] Make loop var type human readable

2020-05-26 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis created this revision. zinovy.nis added reviewers: angelgarcia, alexfh. zinovy.nis added a project: clang-tools-extra. Herald added subscribers: cfe-commits, xazax.hun. Herald added a project: clang. zinovy.nis edited the summary of this revision. Without this patch

[PATCH] D80536: [clang-tidy][modernize-loop-convert] Make loop var type human readable

2020-05-29 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. Nathan, do you have any other questions/comments? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80536/new/ https://reviews.llvm.org/D80536 ___ cfe-commits mailing list

[PATCH] D80896: [clang-tidy][misc-redundant-expression] Fix crash on CXXFoldExpr

2020-05-31 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis created this revision. zinovy.nis added a reviewer: etienneb. Herald added subscribers: cfe-commits, xazax.hun. Herald added a project: clang. Fix for a crash from https://bugs.llvm.org/show_bug.cgi?id=44256 Bug: https://bugs.llvm.org/show_bug.cgi?id=44256 Repository: rG LLVM

[PATCH] D80896: [clang-tidy][misc-redundant-expression] Fix crash on CXXFoldExpr

2020-05-31 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 267518. zinovy.nis added a comment. Fix formatting. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80896/new/ https://reviews.llvm.org/D80896 Files: clang-tools-extra/clang-tidy/misc/RedundantExpressionCheck.cpp

[PATCH] D80896: [clang-tidy][misc-redundant-expression] Fix crash on CXXFoldExpr

2020-06-01 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 267546. zinovy.nis added a comment. Fix and simplify the condition. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80896/new/ https://reviews.llvm.org/D80896 Files: clang-tools-extra/clang-tidy/misc/RedundantExpressionCheck.cpp

[PATCH] D80896: [clang-tidy][misc-redundant-expression] Support for CXXFoldExpr

2020-06-01 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis marked 2 inline comments as done. zinovy.nis added inline comments. Comment at: clang-tools-extra/test/clang-tidy/checkers/misc-redundant-expression.cpp:18 +namespace no_crash { +struct Foo {}; I had to move this up as no warnings were generated in

[PATCH] D80896: [clang-tidy][misc-redundant-expression] Support for CXXFoldExpr

2020-06-01 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 267565. zinovy.nis added a comment. - Fix test. - Simplify the code. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80896/new/ https://reviews.llvm.org/D80896 Files: clang-tools-extra/clang-tidy/misc/RedundantExpressionCheck.cpp

[PATCH] D80896: [clang-tidy][misc-redundant-expression] Support for CXXFoldExpr

2020-06-02 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. @njames93, do you still have any comments? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80896/new/ https://reviews.llvm.org/D80896 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D80536: [clang-tidy][modernize-loop-convert] Make loop var type human readable

2020-05-27 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. In D80536#2055500 , @njames93 wrote: > I'm having trouble with the reproduction of this - > https://godbolt.org/z/tsMfcj. > Aside from that this needs some test cases to demonstrate the patch is > indeed working Thanks.

[PATCH] D80536: [clang-tidy][modernize-loop-convert] Make loop var type human readable

2020-06-04 Thread Zinovy Nis via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG6271b96bef47: [clang-tidy][modernize-loop-convert] Make loop var type human readable (authored by zinovy.nis). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D80896: [clang-tidy][misc-redundant-expression] Support for CXXFoldExpr

2020-06-05 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. In D80896#2076735 , @njames93 wrote: > How are you landing these changes, because the commit message isn't lining up > with the PR name? It was my fault: I hadn't changed a title in my local branch and pushed it with git.

[PATCH] D80896: [clang-tidy][misc-redundant-expression] Support for CXXFoldExpr

2020-06-04 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 268527. zinovy.nis added a comment. Simplify test. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80896/new/ https://reviews.llvm.org/D80896 Files: clang-tools-extra/clang-tidy/misc/RedundantExpressionCheck.cpp

[PATCH] D80896: [clang-tidy][misc-redundant-expression] Support for CXXFoldExpr

2020-06-04 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis marked an inline comment as done. zinovy.nis added inline comments. Comment at: clang-tools-extra/test/clang-tidy/checkers/misc-redundant-expression.cpp:196 bool operator>(const MyStruct& lhs, MyStruct& rhs) { rhs.x--; return lhs.x > rhs.x; } bool

[PATCH] D80896: [clang-tidy][misc-redundant-expression] Support for CXXFoldExpr

2020-06-04 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. @njames93, @aaron.ballman do you have any other comments? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80896/new/ https://reviews.llvm.org/D80896 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

<    1   2   3   >