[PATCH] D113847: [clang-tidy][NFC] Simplify ClangTidyStats
Carlos Galvez via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Nov 15 09:05:37 PST 2021
carlosgalvezp updated this revision to Diff 387290.
carlosgalvezp added a comment.
Fix refactoring bug.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D113847/new/
https://reviews.llvm.org/D113847
Files:
clang-tools-extra/clang-tidy/ClangTidyDiagnosticConsumer.h
Index: clang-tools-extra/clang-tidy/ClangTidyDiagnosticConsumer.h
===================================================================
--- clang-tools-extra/clang-tidy/ClangTidyDiagnosticConsumer.h
+++ clang-tools-extra/clang-tidy/ClangTidyDiagnosticConsumer.h
@@ -45,18 +45,13 @@
std::vector<std::string> EnabledDiagnosticAliases;
};
-/// Contains displayed and ignored diagnostic counters for a ClangTidy
-/// run.
+/// Contains displayed and ignored diagnostic counters for a ClangTidy run.
struct ClangTidyStats {
- ClangTidyStats()
- : ErrorsDisplayed(0), ErrorsIgnoredCheckFilter(0), ErrorsIgnoredNOLINT(0),
- ErrorsIgnoredNonUserCode(0), ErrorsIgnoredLineFilter(0) {}
-
- unsigned ErrorsDisplayed;
- unsigned ErrorsIgnoredCheckFilter;
- unsigned ErrorsIgnoredNOLINT;
- unsigned ErrorsIgnoredNonUserCode;
- unsigned ErrorsIgnoredLineFilter;
+ unsigned ErrorsDisplayed = 0;
+ unsigned ErrorsIgnoredCheckFilter = 0;
+ unsigned ErrorsIgnoredNOLINT = 0;
+ unsigned ErrorsIgnoredNonUserCode = 0;
+ unsigned ErrorsIgnoredLineFilter = 0;
unsigned errorsIgnored() const {
return ErrorsIgnoredNOLINT + ErrorsIgnoredCheckFilter +
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D113847.387290.patch
Type: text/x-patch
Size: 1165 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20211115/24b7219c/attachment.bin>
More information about the cfe-commits
mailing list