Modify command options to use the new arguments mechanism.  Now all command option
arguments are specified in a standardized way, will have a standardized name, and
have functioning help.

The next step is to start writing useful help for all the argument types.



git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@115335 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/Commands/CommandObjectImage.cpp b/source/Commands/CommandObjectImage.cpp
index 30e9195..b8c92ae 100644
--- a/source/Commands/CommandObjectImage.cpp
+++ b/source/Commands/CommandObjectImage.cpp
@@ -1174,14 +1174,14 @@
 lldb::OptionDefinition
 CommandObjectImageList::CommandOptions::g_option_table[] =
 {
-{ LLDB_OPT_SET_1, false, "arch",       'a', optional_argument, NULL, 0, "<width>",   "Display the architecture when listing images."},
-{ LLDB_OPT_SET_1, false, "uuid",       'u', no_argument,       NULL, 0, NULL,        "Display the UUID when listing images."},
-{ LLDB_OPT_SET_1, false, "fullpath",   'f', optional_argument, NULL, 0, "<width>",   "Display the fullpath to the image object file."},
-{ LLDB_OPT_SET_1, false, "directory",  'd', optional_argument, NULL, 0, "<width>",   "Display the directory with optional width for the image object file."},
-{ LLDB_OPT_SET_1, false, "basename",   'b', optional_argument, NULL, 0, "<width>",   "Display the basename with optional width for the image object file."},
-{ LLDB_OPT_SET_1, false, "symfile",    's', optional_argument, NULL, 0, "<width>",   "Display the fullpath to the image symbol file with optional width."},
-{ LLDB_OPT_SET_1, false, "symfile-basename", 'S', optional_argument, NULL, 0, "<width>",   "Display the basename to the image symbol file with optional width."},
-{ 0, false, NULL, 0, 0, NULL, 0, NULL, NULL }
+{ LLDB_OPT_SET_1, false, "arch",       'a', optional_argument, NULL, 0, eArgTypeWidth,   "Display the architecture when listing images."},
+{ LLDB_OPT_SET_1, false, "uuid",       'u', no_argument,       NULL, 0, eArgTypeNone,        "Display the UUID when listing images."},
+{ LLDB_OPT_SET_1, false, "fullpath",   'f', optional_argument, NULL, 0, eArgTypeWidth,   "Display the fullpath to the image object file."},
+{ LLDB_OPT_SET_1, false, "directory",  'd', optional_argument, NULL, 0, eArgTypeWidth,   "Display the directory with optional width for the image object file."},
+{ LLDB_OPT_SET_1, false, "basename",   'b', optional_argument, NULL, 0, eArgTypeWidth,   "Display the basename with optional width for the image object file."},
+{ LLDB_OPT_SET_1, false, "symfile",    's', optional_argument, NULL, 0, eArgTypeWidth,   "Display the fullpath to the image symbol file with optional width."},
+{ LLDB_OPT_SET_1, false, "symfile-basename", 'S', optional_argument, NULL, 0, eArgTypeWidth,   "Display the basename to the image symbol file with optional width."},
+{ 0, false, NULL, 0, 0, NULL, 0, eArgTypeNone, NULL }
 };
 
 
@@ -1531,17 +1531,17 @@
 lldb::OptionDefinition
 CommandObjectImageLookup::CommandOptions::g_option_table[] =
 {
-{ LLDB_OPT_SET_1,   true,  "address",    'a', required_argument, NULL, 0, "<addr>",    "Lookup an address in one or more executable images."},
-{ LLDB_OPT_SET_1,   false, "offset",     'o', required_argument, NULL, 0, "<offset>",  "When looking up an address subtract <offset> from any addresses before doing the lookup."},
-{ LLDB_OPT_SET_2,   true,  "symbol",     's', required_argument, NULL, 0, "<name>",    "Lookup a symbol by name in the symbol tables in one or more executable images."},
-{ LLDB_OPT_SET_2,   false, "regex",      'r', no_argument,       NULL, 0, NULL,        "The <name> argument for name lookups are regular expressions."},
-{ LLDB_OPT_SET_3,   true,  "file",       'f', required_argument, NULL, 0, "<file>",    "Lookup a file by fullpath or basename in one or more executable images."},
-{ LLDB_OPT_SET_3,   false, "line",       'l', required_argument, NULL, 0, "<line>",    "Lookup a line number in a file (must be used in conjunction with --file)."},
-{ LLDB_OPT_SET_3,   false, "no-inlines", 'i', no_argument,       NULL, 0, NULL,        "Check inline line entries (must be used in conjunction with --file)."},
-{ LLDB_OPT_SET_4,   true,  "function",   'n', required_argument, NULL, 0, "<name>",    "Lookup a function by name in the debug symbols in one or more executable images."},
-{ LLDB_OPT_SET_5,   true,  "type",       't', required_argument, NULL, 0, "<name>",    "Lookup a type by name in the debug symbols in one or more executable images."},
-{ LLDB_OPT_SET_ALL, false, "verbose",    'v', no_argument,       NULL, 0, NULL,        "Enable verbose lookup information."},
-{ 0, false, NULL,           0, 0,                 NULL, 0, NULL, NULL }
+{ LLDB_OPT_SET_1,   true,  "address",    'a', required_argument, NULL, 0, eArgTypeAddress,    "Lookup an address in one or more executable images."},
+{ LLDB_OPT_SET_1,   false, "offset",     'o', required_argument, NULL, 0, eArgTypeOffset,  "When looking up an address subtract <offset> from any addresses before doing the lookup."},
+{ LLDB_OPT_SET_2,   true,  "symbol",     's', required_argument, NULL, 0, eArgTypeSymbol,    "Lookup a symbol by name in the symbol tables in one or more executable images."},
+{ LLDB_OPT_SET_2,   false, "regex",      'r', no_argument,       NULL, 0, eArgTypeNone,        "The <name> argument for name lookups are regular expressions."},
+{ LLDB_OPT_SET_3,   true,  "file",       'f', required_argument, NULL, 0, eArgTypeFilename,    "Lookup a file by fullpath or basename in one or more executable images."},
+{ LLDB_OPT_SET_3,   false, "line",       'l', required_argument, NULL, 0, eArgTypeLineNum,    "Lookup a line number in a file (must be used in conjunction with --file)."},
+{ LLDB_OPT_SET_3,   false, "no-inlines", 'i', no_argument,       NULL, 0, eArgTypeNone,        "Check inline line entries (must be used in conjunction with --file)."},
+{ LLDB_OPT_SET_4,   true,  "function",   'n', required_argument, NULL, 0, eArgTypeFunctionName,    "Lookup a function by name in the debug symbols in one or more executable images."},
+{ LLDB_OPT_SET_5,   true,  "type",       't', required_argument, NULL, 0, eArgTypeName,    "Lookup a type by name in the debug symbols in one or more executable images."},
+{ LLDB_OPT_SET_ALL, false, "verbose",    'v', no_argument,       NULL, 0, eArgTypeNone,        "Enable verbose lookup information."},
+{ 0, false, NULL,           0, 0,                 NULL, 0, eArgTypeNone, NULL }
 };