diff options
author | Kazu Hirata <kazu@google.com> | 2022-06-12 18:46:25 -0700 |
---|---|---|
committer | Kazu Hirata <kazu@google.com> | 2022-06-12 18:46:25 -0700 |
commit | 6c39687567faee49b7bccdcaaaa35db0d397c19d (patch) | |
tree | 99f43eb42f5c76b86703d455914e86e87ffbf2d2 /llvm/lib/Support/CommandLine.cpp | |
parent | df792bcb02264574060910b2a1575fe64365f699 (diff) | |
download | llvm-6c39687567faee49b7bccdcaaaa35db0d397c19d.zip llvm-6c39687567faee49b7bccdcaaaa35db0d397c19d.tar.gz llvm-6c39687567faee49b7bccdcaaaa35db0d397c19d.tar.bz2 |
[Support] Use default member initialization (NFC)
Identified with modernize-use-default-member-init.
Diffstat (limited to 'llvm/lib/Support/CommandLine.cpp')
-rw-r--r-- | llvm/lib/Support/CommandLine.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Support/CommandLine.cpp b/llvm/lib/Support/CommandLine.cpp index 742e245..eb6c04d 100644 --- a/llvm/lib/Support/CommandLine.cpp +++ b/llvm/lib/Support/CommandLine.cpp @@ -166,7 +166,7 @@ public: // This collects the different subcommands that have been registered. SmallPtrSet<SubCommand *, 4> RegisteredSubCommands; - CommandLineParser() : ActiveSubCommand(nullptr) { + CommandLineParser() { registerSubCommand(&*TopLevelSubCommand); registerSubCommand(&*AllSubCommands); } @@ -418,7 +418,7 @@ public: } private: - SubCommand *ActiveSubCommand; + SubCommand *ActiveSubCommand = nullptr; Option *LookupOption(SubCommand &Sub, StringRef &Arg, StringRef &Value); Option *LookupLongOption(SubCommand &Sub, StringRef &Arg, StringRef &Value, |