Watchpoint IDs and ID Ranges are not quite the same as Breakpoint IDs and ID Ranges.
Add eArgTypeWatchpointID and eArgTypeWatchpointIDRange to the CommandArgumentType enums and
modify the signature of CommandObject::AddIDsArgumentData() from:

    AddIDsArgumentData(CommandArgumentEntry &arg)

to:

    AddIDsArgumentData(CommandArgumentEntry &arg, CommandArgumentType ID, CommandArgumentType IDRange)

to accommodate.


git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@140346 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/Commands/CommandObjectBreakpoint.cpp b/source/Commands/CommandObjectBreakpoint.cpp
index f528dfd..11e0fad 100644
--- a/source/Commands/CommandObjectBreakpoint.cpp
+++ b/source/Commands/CommandObjectBreakpoint.cpp
@@ -805,7 +805,7 @@
                    NULL)
 {
     CommandArgumentEntry arg;
-    CommandObject::AddIDsArgumentData(arg);
+    CommandObject::AddIDsArgumentData(arg, eArgTypeBreakpointID, eArgTypeBreakpointIDRange);
     // Add the entry for the first argument for this command to the object's arguments vector.
     m_arguments.push_back (arg);   
 }
@@ -906,7 +906,7 @@
                    NULL)
 {
     CommandArgumentEntry arg;
-    CommandObject::AddIDsArgumentData(arg);
+    CommandObject::AddIDsArgumentData(arg, eArgTypeBreakpointID, eArgTypeBreakpointIDRange);
     // Add the entry for the first argument for this command to the object's arguments vector.
     m_arguments.push_back (arg);   
 }
@@ -1187,7 +1187,7 @@
                    NULL)
 {
     CommandArgumentEntry arg;
-    CommandObject::AddIDsArgumentData(arg);
+    CommandObject::AddIDsArgumentData(arg, eArgTypeBreakpointID, eArgTypeBreakpointIDRange);
     // Add the entry for the first argument for this command to the object's arguments vector.
     m_arguments.push_back (arg);   
 }
@@ -1447,7 +1447,7 @@
     m_options (interpreter)
 {
     CommandArgumentEntry arg;
-    CommandObject::AddIDsArgumentData(arg);
+    CommandObject::AddIDsArgumentData(arg, eArgTypeBreakpointID, eArgTypeBreakpointIDRange);
     // Add the entry for the first argument for this command to the object's arguments vector.
     m_arguments.push_back (arg);   
 }
diff --git a/source/Commands/CommandObjectWatchpoint.cpp b/source/Commands/CommandObjectWatchpoint.cpp
index aa3c8e8..151d3d7 100644
--- a/source/Commands/CommandObjectWatchpoint.cpp
+++ b/source/Commands/CommandObjectWatchpoint.cpp
@@ -251,7 +251,7 @@
     m_options(interpreter)
 {
     CommandArgumentEntry arg;
-    CommandObject::AddIDsArgumentData(arg);
+    CommandObject::AddIDsArgumentData(arg, eArgTypeWatchpointID, eArgTypeWatchpointIDRange);
     // Add the entry for the first argument for this command to the object's arguments vector.
     m_arguments.push_back(arg);
 }
@@ -339,7 +339,7 @@
                   NULL)
 {
     CommandArgumentEntry arg;
-    CommandObject::AddIDsArgumentData(arg);
+    CommandObject::AddIDsArgumentData(arg, eArgTypeWatchpointID, eArgTypeWatchpointIDRange);
     // Add the entry for the first argument for this command to the object's arguments vector.
     m_arguments.push_back(arg);
 }
@@ -411,7 +411,7 @@
                   NULL)
 {
     CommandArgumentEntry arg;
-    CommandObject::AddIDsArgumentData(arg);
+    CommandObject::AddIDsArgumentData(arg, eArgTypeWatchpointID, eArgTypeWatchpointIDRange);
     // Add the entry for the first argument for this command to the object's arguments vector.
     m_arguments.push_back(arg);
 }
@@ -489,7 +489,7 @@
                   NULL)
 {
     CommandArgumentEntry arg;
-    CommandObject::AddIDsArgumentData(arg);
+    CommandObject::AddIDsArgumentData(arg, eArgTypeWatchpointID, eArgTypeWatchpointIDRange);
     // Add the entry for the first argument for this command to the object's arguments vector.
     m_arguments.push_back(arg);
 }
diff --git a/source/Interpreter/CommandObject.cpp b/source/Interpreter/CommandObject.cpp
index 56f9eec..2d3a6b7 100644
--- a/source/Interpreter/CommandObject.cpp
+++ b/source/Interpreter/CommandObject.cpp
@@ -744,17 +744,17 @@
 }
 
 void
-CommandObject::AddIDsArgumentData(CommandArgumentEntry &arg)
+CommandObject::AddIDsArgumentData(CommandArgumentEntry &arg, CommandArgumentType ID, CommandArgumentType IDRange)
 {
     CommandArgumentData id_arg;
     CommandArgumentData id_range_arg;
 
     // Create the first variant for the first (and only) argument for this command.
-    id_arg.arg_type = eArgTypeBreakpointID;
+    id_arg.arg_type = ID;
     id_arg.arg_repetition = eArgRepeatOptional;
 
     // Create the second variant for the first (and only) argument for this command.
-    id_range_arg.arg_type = eArgTypeBreakpointIDRange;
+    id_range_arg.arg_type = IDRange;
     id_range_arg.arg_repetition = eArgRepeatOptional;
 
     // The first (and only) argument for this command could be either an id or an id_range.
@@ -850,6 +850,8 @@
     { eArgTypeWidth, "width", CommandCompletions::eNoCompletion, { NULL, false }, "Help text goes here." },
     { eArgTypeNone, "none", CommandCompletions::eNoCompletion, { NULL, false }, "No help available for this." },
     { eArgTypePlatform, "platform-name", CommandCompletions::ePlatformPluginCompletion, { NULL, false }, "The name of an installed platform plug-in . Type 'platform list' to see a complete list of installed platforms." },
+    { eArgTypeWatchpointID, "watchpt-id", CommandCompletions::eNoCompletion, { NULL, false }, "Watchpoint IDs are positive integers." },
+    { eArgTypeWatchpointIDRange, "watchpt-id-list", CommandCompletions::eNoCompletion, { NULL, false }, "For example, '1-3' or '1 to 3'." },
     { eArgTypeWatchType, "watch-type", CommandCompletions::eNoCompletion, { NULL, false }, "Specify the type for a watchpoint." }
 };