[CommandLine] Aliases require an value if their target requires a value.
This can still be overridden by explicitly setting a value requirement on the
alias option, but by default it should be the same.
PR18649
llvm-svn: 200407
diff --git a/llvm/lib/Support/CommandLine.cpp b/llvm/lib/Support/CommandLine.cpp
index 1b4d2c7..16db4d6 100644
--- a/llvm/lib/Support/CommandLine.cpp
+++ b/llvm/lib/Support/CommandLine.cpp
@@ -111,6 +111,13 @@
MarkOptionsChanged();
}
+void Option::removeArgument() {
+ assert(NextRegistered != 0 && "argument never registered");
+ assert(RegisteredOptionList == this && "argument is not the last registered");
+ RegisteredOptionList = NextRegistered;
+ MarkOptionsChanged();
+}
+
// This collects the different option categories that have been registered.
typedef SmallPtrSet<OptionCategory*,16> OptionCatSet;
static ManagedStatic<OptionCatSet> RegisteredOptionCategories;