[PATCH] D154287: [clang-tidy] Add modernize-use-std-format check

2023-08-29 Thread Mike Crowe via Phabricator via cfe-commits
mikecrowe updated this revision to Diff 554486. mikecrowe edited the summary of this revision. mikecrowe added a comment. Fix ReleaseNotes order and remove unnecessary .html from list.rst Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154287/new/ ht

[PATCH] D154287: [clang-tidy] Add modernize-use-std-format check

2023-08-29 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added inline comments. Comment at: clang-tools-extra/docs/ReleaseNotes.rst:168 +- New :doc:`modernize-use-std-format + ` check. Please keep alphabetical order (by check name) in this section. Repository: rG LLVM Github Monorepo CHANGES SINC

[PATCH] D154287: [clang-tidy] Add modernize-use-std-format check

2023-08-29 Thread Mike Crowe via Phabricator via cfe-commits
mikecrowe updated this revision to Diff 55. mikecrowe added a comment. Rebase and fix minor doc conflicts. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154287/new/ https://reviews.llvm.org/D154287 Files: clang-tools-extra/clang-tidy/moderni

[PATCH] D154287: [clang-tidy] Add modernize-use-std-format check

2023-08-02 Thread Mike Crowe via Phabricator via cfe-commits
mikecrowe updated this revision to Diff 546418. mikecrowe added a comment. Rebase on top of D156616 and add more tests Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154287/new/ https://reviews.llvm.org/D154287 Fi

[PATCH] D154287: [clang-tidy] Add modernize-use-std-format check

2023-07-10 Thread Mike Crowe via Phabricator via cfe-commits
mikecrowe updated this revision to Diff 538806. mikecrowe added a comment. Use isOrdinary in stringLiteral() match on first argument Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154287/new/ https://reviews.llvm.org/D154287 Files: clang-tools-ex

[PATCH] D154287: [clang-tidy] Add modernize-use-std-format check

2023-07-10 Thread Mike Crowe via Phabricator via cfe-commits
mikecrowe added inline comments. Comment at: clang-tools-extra/clang-tidy/modernize/UseStdFormatCheck.cpp:46 +void UseStdFormatCheck::registerMatchers(MatchFinder *Finder) { + Finder->addMatcher( + callExpr(argumentCountAtLeast(1), hasArgument(0, stringLiteral()), -

[PATCH] D154287: [clang-tidy] Add modernize-use-std-format check

2023-07-10 Thread Piotr Zegar via Phabricator via cfe-commits
PiotrZSL added inline comments. Comment at: clang-tools-extra/clang-tidy/modernize/UseStdFormatCheck.cpp:46 +void UseStdFormatCheck::registerMatchers(MatchFinder *Finder) { + Finder->addMatcher( + callExpr(argumentCountAtLeast(1), hasArgument(0, stringLiteral()), --

[PATCH] D154287: [clang-tidy] Add modernize-use-std-format check

2023-07-09 Thread Mike Crowe via Phabricator via cfe-commits
mikecrowe added inline comments. Comment at: clang-tools-extra/clang-tidy/modernize/UseStdFormatCheck.cpp:46 +void UseStdFormatCheck::registerMatchers(MatchFinder *Finder) { + Finder->addMatcher( + callExpr(argumentCountAtLeast(1), hasArgument(0, stringLiteral()), -

[PATCH] D154287: [clang-tidy] Add modernize-use-std-format check

2023-07-09 Thread Mike Crowe via Phabricator via cfe-commits
mikecrowe updated this revision to Diff 538427. mikecrowe marked 3 inline comments as done. mikecrowe added a comment. Address review comments and improve documentation. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154287/new/ https://reviews.llvm

[PATCH] D154287: [clang-tidy] Add modernize-use-std-format check

2023-07-09 Thread Mike Crowe via Phabricator via cfe-commits
mikecrowe marked 9 inline comments as done. mikecrowe added a comment. Thanks for the reviews! Comment at: clang-tools-extra/clang-tidy/modernize/UseStdFormatCheck.cpp:81 + << ReplacementFormatFunction + << OldFunction->ge

[PATCH] D154287: [clang-tidy] Add modernize-use-std-format check

2023-07-03 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added inline comments. Comment at: clang-tools-extra/docs/clang-tidy/checks/modernize/use-std-format.rst:6 + +Converts calls to ``absl::StrFormat`` to equivalent calls to C++20's +``std::format`` function, modifying the format string appropriately. The ---

[PATCH] D154287: [clang-tidy] Add modernize-use-std-format check

2023-07-02 Thread Piotr Zegar via Phabricator via cfe-commits
PiotrZSL added a comment. To be honest, I do not see to much use case for this check. But that's fine. Comment at: clang-tools-extra/clang-tidy/modernize/UseStdFormatCheck.cpp:46-51 + StatementMatcher StrFormatMatcher = + callExpr(callee(functionDecl(matchers::matchesAnyL

[PATCH] D154287: [clang-tidy] Add modernize-use-std-format check

2023-07-01 Thread Mike Crowe via Phabricator via cfe-commits
mikecrowe created this revision. mikecrowe added a reviewer: PiotrZSL. Herald added subscribers: carlosgalvezp, xazax.hun. Herald added a reviewer: njames93. Herald added a project: All. mikecrowe requested review of this revision. Herald added a project: clang-tools-extra. Herald added a subscribe