[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 Index:

[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 Index:

[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 Mo

[PATCH] D44295: [clang-tidy] Detects and fixes calls to grand-...parent virtual methods instead of calls to parent's virtual methods

2018-03-22 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 139496. zinovy.nis added a comment. Aaron, I applied the changes you suggest. I also found and fixed a new case when grandparent method is called via 'typedef'ed or 'using' type. There's also a new test (class C2) for it. Repository: rCTE Clang Tools

[PATCH] D44295: [clang-tidy] Detects and fixes calls to grand-...parent virtual methods instead of calls to parent's virtual methods

2018-03-22 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 139499. zinovy.nis marked an inline comment as done. zinovy.nis added a comment. camelCase last minute fix. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D44295 Files: clang-tidy/bugprone/BugproneTidyModule.cpp clang-tidy/bugprone/CM

[PATCH] D44295: [clang-tidy] Detects and fixes calls to grand-...parent virtual methods instead of calls to parent's virtual methods

2018-03-22 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis marked 9 inline comments as done. zinovy.nis added inline comments. Comment at: docs/clang-tidy/checks/bugprone-parent-virtual-call.rst:6 + +Detects and fixes calls to grand-...parent virtual methods instead of calls +to parent's virtual methods. aaron

[PATCH] D44295: [clang-tidy] Detects and fixes calls to grand-...parent virtual methods instead of calls to parent's virtual methods

2018-03-23 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 139646. zinovy.nis added a comment. - Rebased. - Added 1 more test for namespaced base clases - Fixed minor issues. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D44295 Files: clang-tidy/bugprone/BugproneTidyModule.cpp clang-tidy/bug

[PATCH] D44295: [clang-tidy] Detects and fixes calls to grand-...parent virtual methods instead of calls to parent's virtual methods

2018-03-26 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 139805. zinovy.nis retitled this revision from "[clang-tidy] Detect and fix calls to grand-...parent virtual methods instead of calls to parent's virtual methods" to "[clang-tidy] Detects and fixes calls to grand-...parent virtual methods instead of calls

[PATCH] D44295: [clang-tidy] Detects and fixes calls to grand-...parent virtual methods instead of calls to parent's virtual methods

2018-03-26 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 139834. zinovy.nis added a comment. - Updated warning message to > warning: qualified name 'A::foo' refers to a member overridden in subclass; > did you mean 'B'? [bugprone-parent-virtual-call] https://reviews.llvm.org/D44295 Files: clang-tidy/bu

[PATCH] D44906: [clang-tidy] Define __clang_analyzer__ macro for clang-tidy for compatibility with clang static analyzer

2018-03-26 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis created this revision. zinovy.nis added a project: clang-tools-extra. Herald added subscribers: cfe-commits, a.sidorin, xazax.hun. Herald added a reviewer: george.karpenkov. This macro is widely used in many well-known projects, ex. Chromium

[PATCH] D44906: [clang-tidy] Define __clang_analyzer__ macro for clang-tidy for compatibility with clang static analyzer

2018-03-27 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added inline comments. Comment at: clang-tidy/ClangTidy.cpp:490 +CommandLineArguments AdjustedArgs = Args; +AdjustedArgs.emplace_back("-D__clang_analyzer__"); +return AdjustedArgs; alexfh wrote: > I wonder whether we should inst

[PATCH] D44295: [clang-tidy] Detects and fixes calls to grand-...parent virtual methods instead of calls to parent's virtual methods

2018-03-30 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 140475. zinovy.nis marked 3 inline comments as done. zinovy.nis added a comment. - Cosmetic fixes. https://reviews.llvm.org/D44295 Files: clang-tidy/bugprone/BugproneTidyModule.cpp clang-tidy/bugprone/CMakeLists.txt clang-tidy/bugprone/ParentVirtua

[PATCH] D44295: [clang-tidy] Detects and fixes calls to grand-...parent virtual methods instead of calls to parent's virtual methods

2018-03-30 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. BTW, I've recently found few dozens of issues in the Chromium code with my check. For ex.: browser/src/cc/layers/nine_patch_layer_impl.cc:89:51: warning: qualified name 'cc::LayerImpl::LayerAsJson' refers to a member overridden in subclass; did you mean 'cc::UIRes

[PATCH] D44906: [clang-tidy] Define __clang_analyzer__ macro for clang-tidy for compatibility with clang static analyzer

2018-04-01 Thread Zinovy Nis via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL328932: [clang-tidy] Define __clang_analyzer__ macro for clang-tidy for compatibility… (authored by zinovy.nis, committed by ). Herald added subscribers: llvm-commits, klimek. Changed prior to commit: h

[PATCH] D44295: [clang-tidy] Detects and fixes calls to grand-...parent virtual methods instead of calls to parent's virtual methods

2018-04-01 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 140579. zinovy.nis added a comment. - Minor cosmetic fix: use lexical representation instead of semanic for printing callee string. It helps to print class names hidden behind 'typedef' and 'using': using A1 = A; typedef A A2; class C2 : publi

[PATCH] D45160: [clang-apply-replacements] Make clang-apply-replacements installable

2018-04-02 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis created this revision. Herald added subscribers: cfe-commits, mgorny. Add a new target for install: **install-clang-apply-replacements** So if you need clang-tidy and clang-apply-replacements tools only, you may build and install only these tools: make install-clang-tidy install-cla

[PATCH] D44906: [clang-tidy] Define __clang_analyzer__ macro for clang-tidy for compatibility with clang static analyzer

2018-04-02 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a subscriber: george.karpenkov. zinovy.nis added a comment. Looks like quotes are required. Thanks for pointing! I'll submit a patch for this. пн, 2 апр. 2018 г. в 17:28, Nico Weber via Phabricator < revi...@reviews.llvm.org>: > thakis added a comment. > > Actually, it doesn't

[PATCH] D44295: [clang-tidy] Detects and fixes calls to grand-...parent virtual methods instead of calls to parent's virtual methods

2018-04-05 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 141199. zinovy.nis added a comment. - Switched to use 'tooling::fixit::getText' for qualified names. - Shortened test code with {{.*}}. https://reviews.llvm.org/D44295 Files: clang-tidy/bugprone/BugproneTidyModule.cpp clang-tidy/bugprone/CMakeLists.t

[PATCH] D44295: [clang-tidy] Detect and fix calls to grand-...parent virtual methods instead of calls to parent's virtual methods

2018-04-06 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. Alexander, thanks for your patience and comments :-) https://reviews.llvm.org/D44295 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D44295: [clang-tidy] Detect and fix calls to grand-...parent virtual methods instead of calls to parent's virtual methods

2018-04-06 Thread Zinovy Nis via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rCTE329448: [clang-tidy] Check if grand-..parent's virtual method was called instead of… (authored by zinovy.nis, committed by ). Changed prior to commit: https://reviews.llvm.org/D44295?vs=141199&id=1414

[PATCH] D45405: [clang-tidy] [modernize-use-auto] Add a threshold for minimal type name length to be replaced with 'auto'

2018-04-07 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis created this revision. zinovy.nis added reviewers: angelgarcia, malcolm.parsons, alexfh. zinovy.nis added a project: clang-tools-extra. Herald added subscribers: cfe-commits, xazax.hun. The threshold option is 'MinTypeNameLength' with default value '0' which means 'replace any lengths'

[PATCH] D45405: [clang-tidy] [modernize-use-auto] Add a threshold for minimal type name length to be replaced with 'auto'

2018-04-08 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 141561. zinovy.nis added a comment. - Updated ReleaseNotes. https://reviews.llvm.org/D45405 Files: clang-tidy/modernize/UseAutoCheck.cpp clang-tidy/modernize/UseAutoCheck.h docs/ReleaseNotes.rst docs/clang-tidy/checks/modernize-use-auto.rst tes

[PATCH] D45405: [clang-tidy] [modernize-use-auto] Add a threshold for minimal type name length to be replaced with 'auto'

2018-04-09 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added inline comments. Comment at: clang-tidy/modernize/UseAutoCheck.cpp:290 +: ClangTidyCheck(Name, Context), RemoveStars(Options.get("RemoveStars", 0)), + MinTypeNameLength(Options.get("MinTypeNameLength", 0)) {} lebedev.ri wrote: > alexf

[PATCH] D45405: [clang-tidy] [modernize-use-auto] Add a threshold for minimal type name length to be replaced with 'auto'

2018-04-09 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added inline comments. Comment at: clang-tidy/modernize/UseAutoCheck.cpp:290 +: ClangTidyCheck(Name, Context), RemoveStars(Options.get("RemoveStars", 0)), + MinTypeNameLength(Options.get("MinTypeNameLength", 0)) {} alexfh wrote: > alexfh wr

[PATCH] D45405: [clang-tidy] [modernize-use-auto] Add a threshold for minimal type name length to be replaced with 'auto'

2018-04-09 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 141719. zinovy.nis marked 9 inline comments as done. zinovy.nis added a comment. - Default value is **5**. - Switched to 'tooling::fixit::getText'. - Updated rst docs. https://reviews.llvm.org/D45405 Files: clang-tidy/modernize/UseAutoCheck.cpp clang

[PATCH] D45405: [clang-tidy] [modernize-use-auto] Add a threshold for minimal type name length to be replaced with 'auto'

2018-04-10 Thread Zinovy Nis via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL329730: [clang-tidy] [modernize-use-auto] Add a threshold for minimal type name length… (authored by zinovy.nis, committed by ). Herald added subscribers: llvm-commits, klimek. Changed prior to commit:

[PATCH] D45405: [clang-tidy] [modernize-use-auto] Add a threshold for minimal type name length to be replaced with 'auto'

2018-04-10 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a subscriber: angelgarcia. zinovy.nis added a comment. Roman, I see you've fixed them. Thanks a lot! I did not face with these errors on MSVS'201 so had no chance to fix early. ср, 11 апр. 2018 г. в 0:02, Roman Lebedev via Phabricator < revi...@reviews.llvm.org>: > lebedev.ri a

[PATCH] D45405: [clang-tidy] [modernize-use-auto] Add a threshold for minimal type name length to be replaced with 'auto'

2018-04-11 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. The build was broken by someone else's commit then. From my side there was a warning only I fixed immediately. ср, 11 апр. 2018 г. в 16:26, Alexander Kornienko via Phabricator < revi...@reviews.llvm.org>: > alexfh added a comment. > > In https://reviews.llvm.org/D454

[PATCH] D116478: [clang-tidy] A semicolon-separated list of the names of functions or methods to be considered as not having side-effects

2022-01-20 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. Any other comments? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116478/new/ https://reviews.llvm.org/D116478 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo

[PATCH] D116478: [clang-tidy] A semicolon-separated list of the names of functions or methods to be considered as not having side-effects

2022-01-22 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 402199. zinovy.nis added a comment. - Remove unused include. - Update release notes. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116478/new/ https://reviews.llvm.org/D116478 Files: clang-tools-extra/clang-tidy/bugprone/AssertSideEffectCheck.

[PATCH] D116478: [clang-tidy] A semicolon-separated list of the names of functions or methods to be considered as not having side-effects

2022-01-25 Thread Zinovy Nis via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG19d7a0b47b68: [clang-tidy] [bugprone-assert-side-effect] Ignore list for functions/methods (authored by zinovy.nis). Changed prior to commit: https://reviews.llvm.org/D116478?vs=402199&id=402956#toc Re

[PATCH] D116478: [clang-tidy] A semicolon-separated list of the names of functions or methods to be considered as not having side-effects

2022-01-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-tools-extra/docs/ReleaseNotes.rst:161 + check now supports an ``IgnoredFunctions`` option to explicitly consider + the specified semicolon-separated functions list as not any having

[PATCH] D116478: [clang-tidy] A comma-separated list of the names of functions or methods to be considered as not having side-effects

2022-01-01 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis created this revision. zinovy.nis added reviewers: alexfh, aaron.ballman. zinovy.nis added a project: clang-tools-extra. Herald added subscribers: carlosgalvezp, xazax.hun. zinovy.nis requested review of this revision. Herald added a subscriber: cfe-commits. A comma-separated list of th

[PATCH] D116478: [clang-tidy] A comma-separated list of the names of functions or methods to be considered as not having side-effects

2022-01-01 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 396867. zinovy.nis added a comment. Fix clang-format issues. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116478/new/ https://reviews.llvm.org/D116478 Files: clang-tools-extra/clang-tidy/ClangTidyCheck.cpp clang-tools-extra/clang-tidy/bugpr

[PATCH] D116478: [clang-tidy] A comma-separated list of the names of functions or methods to be considered as not having side-effects

2022-01-01 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 396869. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116478/new/ https://reviews.llvm.org/D116478 Files: clang-tools-extra/clang-tidy/bugprone/AssertSideEffectCheck.cpp clang-tools-extra/clang-tidy/bugprone/AssertSideEffectCheck.h clang-too

[PATCH] D116478: [clang-tidy] A comma-separated list of the names of functions or methods to be considered as not having side-effects

2022-01-02 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 396914. zinovy.nis added a comment. Updated release notes. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116478/new/ https://reviews.llvm.org/D116478 Files: clang-tools-extra/clang-tidy/bugprone/AssertSideEffectCheck.cpp clang-tools-extra/cl

[PATCH] D116478: [clang-tidy] A comma-separated list of the names of functions or methods to be considered as not having side-effects

2022-01-02 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis added a comment. In D116478#3216082 , @Eugene.Zelenko wrote: > Please mention new option in Release Notes (in changes in existing checks > section). Done CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116478/new/ https://reviews.ll

[PATCH] D116478: [clang-tidy] A comma-separated list of the names of functions or methods to be considered as not having side-effects

2022-01-02 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 396927. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116478/new/ https://reviews.llvm.org/D116478 Files: clang-tools-extra/clang-tidy/bugprone/AssertSideEffectCheck.cpp clang-tools-extra/clang-tidy/bugprone/AssertSideEffectCheck.h clang-too

[PATCH] D116478: [clang-tidy] A comma-separated list of the names of functions or methods to be considered as not having side-effects

2022-01-09 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 398408. zinovy.nis added a comment. - ``FunctionException`` -> ``IgnoredFunctions`` - Fixed double ticks in rst docs. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116478/new/ https://reviews.llvm.org/D116478 Files: clang-tools-extra/clang-tid

[PATCH] D116478: [clang-tidy] A comma-separated list of the names of functions or methods to be considered as not having side-effects

2022-01-09 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 398409. zinovy.nis marked 5 inline comments as done. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116478/new/ https://reviews.llvm.org/D116478 Files: clang-tools-extra/clang-tidy/bugprone/AssertSideEffectCheck.cpp clang-tools-extra/clang-tidy

[PATCH] D116478: [clang-tidy] A comma-separated list of the names of functions or methods to be considered as not having side-effects

2022-01-09 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 398410. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116478/new/ https://reviews.llvm.org/D116478 Files: clang-tools-extra/clang-tidy/bugprone/AssertSideEffectCheck.cpp clang-tools-extra/clang-tidy/bugprone/AssertSideEffectCheck.h clang-too

[PATCH] D116478: [clang-tidy] A comma-separated list of the names of functions or methods to be considered as not having side-effects

2022-01-15 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 400301. zinovy.nis added a comment. - Support regexp for list of ignored functions. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116478/new/ https://reviews.llvm.org/D116478 Files: clang-tools-extra/clang-tidy/bugprone/AssertSideEffectCheck.c

[PATCH] D116478: [clang-tidy] A comma-separated list of the names of functions or methods to be considered as not having side-effects

2022-01-15 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis marked 4 inline comments as done. zinovy.nis added inline comments. Comment at: clang-tools-extra/clang-tidy/bugprone/AssertSideEffectCheck.cpp:57-60 if (const auto *FuncDecl = CExpr->getDirectCallee()) { if (FuncDecl->getDeclName().isIdentifier() && -

[PATCH] D116478: [clang-tidy] A semicolon-separated list of the names of functions or methods to be considered as not having side-effects

2022-01-15 Thread Zinovy Nis via Phabricator via cfe-commits
zinovy.nis updated this revision to Diff 400303. zinovy.nis marked 2 inline comments as done. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116478/new/ https://reviews.llvm.org/D116478 Files: clang-tools-extra/clang-tidy/bugprone/AssertSideEffectCheck.cpp clang-tools-extra/clang-tidy

<    1   2   3