diff options
author | Sean Callanan <scallanan@apple.com> | 2012-10-24 01:12:14 +0000 |
---|---|---|
committer | Sean Callanan <scallanan@apple.com> | 2012-10-24 01:12:14 +0000 |
commit | 3154255fd6051ad200646203f7da742bc6b542fc (patch) | |
tree | 90c80d0011820f4fc4804edd165be60ee720e915 /lldb/source/Commands/CommandObjectTarget.cpp | |
parent | ec57ab374b1ff5a77adfd5bc7992040548dfe922 (diff) | |
download | bcm5719-llvm-3154255fd6051ad200646203f7da742bc6b542fc.tar.gz bcm5719-llvm-3154255fd6051ad200646203f7da742bc6b542fc.zip |
This is a fix for the command option parser.
There was a generic catch-all type for path arguments
called "eArgTypePath," and a specialized version
called "eArgTypeFilename." It turns out all the
cases where we used eArgTypePath we could have
used Filename or we explicitly meant a directory.
I changed Path to DirectoryName, made it use the
directory completer, and rationalized the uses of
Path.
<rdar://problem/12559915>
llvm-svn: 166533
Diffstat (limited to 'lldb/source/Commands/CommandObjectTarget.cpp')
-rw-r--r-- | lldb/source/Commands/CommandObjectTarget.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/lldb/source/Commands/CommandObjectTarget.cpp b/lldb/source/Commands/CommandObjectTarget.cpp index a8da9b880e8..a4a0d8dd618 100644 --- a/lldb/source/Commands/CommandObjectTarget.cpp +++ b/lldb/source/Commands/CommandObjectTarget.cpp @@ -155,7 +155,7 @@ public: m_option_group (interpreter), m_arch_option (), m_platform_options(true), // Do include the "--platform" option in the platform settings by passing true - m_core_file (LLDB_OPT_SET_1, false, "core", 'c', 0, eArgTypePath, "Fullpath to a core file to use for this target.") + m_core_file (LLDB_OPT_SET_1, false, "core", 'c', 0, eArgTypeFilename, "Fullpath to a core file to use for this target.") { CommandArgumentEntry arg; CommandArgumentData file_arg; @@ -584,8 +584,8 @@ public: m_option_group (interpreter), m_option_variable (false), // Don't include frame options m_option_format (eFormatDefault), - m_option_compile_units (LLDB_OPT_SET_1, false, "file", 'f', 0, eArgTypePath, "A basename or fullpath to a file that contains global variables. This option can be specified multiple times."), - m_option_shared_libraries (LLDB_OPT_SET_1, false, "shlib",'s', 0, eArgTypePath, "A basename or fullpath to a shared library to use in the search for global variables. This option can be specified multiple times."), + m_option_compile_units (LLDB_OPT_SET_1, false, "file", 'f', 0, eArgTypeFilename, "A basename or fullpath to a file that contains global variables. This option can be specified multiple times."), + m_option_shared_libraries (LLDB_OPT_SET_1, false, "shlib",'s', 0, eArgTypeFilename, "A basename or fullpath to a shared library to use in the search for global variables. This option can be specified multiple times."), m_varobj_options() { CommandArgumentEntry arg; @@ -1159,7 +1159,7 @@ public: CommandArgumentData path_arg; // Define the first (and only) variant of this arg. - path_arg.arg_type = eArgTypePath; + path_arg.arg_type = eArgTypeDirectoryName; path_arg.arg_repetition = eArgRepeatPlain; // There is only one variant this argument could be; put it into the argument entry. @@ -2556,7 +2556,7 @@ public: "Set the load addresses for one or more sections in a target module.", "target modules load [--file <module> --uuid <uuid>] <sect-name> <address> [<sect-name> <address> ....]"), m_option_group (interpreter), - m_file_option (LLDB_OPT_SET_1, false, "file", 'f', 0, eArgTypePath, "Fullpath or basename for module to load."), + m_file_option (LLDB_OPT_SET_1, false, "file", 'f', 0, eArgTypeFilename, "Fullpath or basename for module to load."), m_slide_option(LLDB_OPT_SET_1, false, "slide", 's', 0, eArgTypeOffset, "Set the load address for all sections to be the virtual address in the file plus the offset.", 0) { m_option_group.Append (&m_uuid_option_group, LLDB_OPT_SET_ALL, LLDB_OPT_SET_1); |