Author: Kazu Hirata Date: 2023-04-25T23:58:24-07:00 New Revision: d12c471b892d2eb3087f7b1f8e13516122535966
URL: https://github.com/llvm/llvm-project/commit/d12c471b892d2eb3087f7b1f8e13516122535966 DIFF: https://github.com/llvm/llvm-project/commit/d12c471b892d2eb3087f7b1f8e13516122535966.diff LOG: [clang-tidy] Modernize ClangTidyValue (NFC) Added: Modified: clang-tools-extra/clang-tidy/ClangTidyOptions.h Removed: ################################################################################ diff --git a/clang-tools-extra/clang-tidy/ClangTidyOptions.h b/clang-tools-extra/clang-tidy/ClangTidyOptions.h index d0df474bc38e0..b3b714353642b 100644 --- a/clang-tools-extra/clang-tidy/ClangTidyOptions.h +++ b/clang-tools-extra/clang-tidy/ClangTidyOptions.h @@ -108,15 +108,15 @@ struct ClangTidyOptions { /// Helper structure for storing option value with priority of the value. struct ClangTidyValue { - ClangTidyValue() : Value(), Priority(0) {} - ClangTidyValue(const char *Value) : Value(Value), Priority(0) {} + ClangTidyValue() = default; + ClangTidyValue(const char *Value) : Value(Value) {} ClangTidyValue(llvm::StringRef Value, unsigned Priority = 0) : Value(Value), Priority(Priority) {} std::string Value; /// Priority stores relative precedence of the value loaded from config /// files to disambiguate local vs global value from diff erent levels. - unsigned Priority; + unsigned Priority = 0; }; typedef std::pair<std::string, std::string> StringPair; typedef llvm::StringMap<ClangTidyValue> OptionMap; _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits