diff options
| author | Dimitry Andric <dim@FreeBSD.org> | 2023-07-26 19:03:47 +0000 |
|---|---|---|
| committer | Dimitry Andric <dim@FreeBSD.org> | 2023-07-26 19:04:23 +0000 |
| commit | 7fa27ce4a07f19b07799a767fc29416f3b625afb (patch) | |
| tree | 27825c83636c4de341eb09a74f49f5d38a15d165 /llvm/lib/Support/CommandLine.cpp | |
| parent | e3b557809604d036af6e00c60f012c2025b59a5e (diff) | |
Diffstat (limited to 'llvm/lib/Support/CommandLine.cpp')
| -rw-r--r-- | llvm/lib/Support/CommandLine.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/llvm/lib/Support/CommandLine.cpp b/llvm/lib/Support/CommandLine.cpp index 66632504d6fb..d3efb8b67be5 100644 --- a/llvm/lib/Support/CommandLine.cpp +++ b/llvm/lib/Support/CommandLine.cpp @@ -208,8 +208,7 @@ public: bool HadErrors = false; if (O->hasArgStr()) { // If it's a DefaultOption, check to make sure it isn't already there. - if (O->isDefaultOption() && - SC->OptionsMap.find(O->ArgStr) != SC->OptionsMap.end()) + if (O->isDefaultOption() && SC->OptionsMap.contains(O->ArgStr)) return; // Add argument to the argument map! @@ -2758,7 +2757,7 @@ StringMap<Option *> &cl::getRegisteredOptions(SubCommand &Sub) { initCommonOptions(); auto &Subs = GlobalParser->RegisteredSubCommands; (void)Subs; - assert(is_contained(Subs, &Sub)); + assert(Subs.contains(&Sub)); return Sub.OptionsMap; } |
