[clang-tidy] Modernize ClangTidyValue (NFC)
authorKazu Hirata <kazu@google.com>
Wed, 26 Apr 2023 06:58:24 +0000 (23:58 -0700)
committerKazu Hirata <kazu@google.com>
Wed, 26 Apr 2023 06:58:24 +0000 (23:58 -0700)
clang-tools-extra/clang-tidy/ClangTidyOptions.h

index d0df474bc38e08de7e82fa06a2e33ef5618ff150..b3b714353642bd3aa7032bbcfddd5bcb5aa07b22 100644 (file)
@@ -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 different levels.
-    unsigned Priority;
+    unsigned Priority = 0;
   };
   typedef std::pair<std::string, std::string> StringPair;
   typedef llvm::StringMap<ClangTidyValue> OptionMap;