diff options
author | Caroline Tice <ctice@apple.com> | 2010-12-07 19:58:26 +0000 |
---|---|---|
committer | Caroline Tice <ctice@apple.com> | 2010-12-07 19:58:26 +0000 |
commit | d9d63369dfd1b31e0eb89ce38d6be12cffdb7274 (patch) | |
tree | 607386f6a51e64cdec6fe99cd64b2ab034dddb6a /lldb/source/Commands/CommandObjectHelp.cpp | |
parent | f844b3b2275fd71a0751c92b432651b64a984786 (diff) | |
download | bcm5719-llvm-d9d63369dfd1b31e0eb89ce38d6be12cffdb7274.tar.gz bcm5719-llvm-d9d63369dfd1b31e0eb89ce38d6be12cffdb7274.zip |
- Fix alias-building & resolving to properly handle optional arguments for command options.
- Add logging for command resolution ('log enable lldb commands')
- Fix alias resolution to properly handle commands that take raw input (resolve the alias, but
don't muck up the raw arguments).
Net result: Among other things, 'expr' command can now take strings with escaped characters and
not have the command handling & alias resolution code muck up the escaped characters. E.g.
'expr printf ("\n\n\tHello there!")' should now work properly.
Not working yet: Creating aliases with raw input for commands that take raw input. Working on that.
e.g. 'command alias print_hi expr printf ("\n\tHi!")' does not work yet.
llvm-svn: 121171
Diffstat (limited to 'lldb/source/Commands/CommandObjectHelp.cpp')
-rw-r--r-- | lldb/source/Commands/CommandObjectHelp.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lldb/source/Commands/CommandObjectHelp.cpp b/lldb/source/Commands/CommandObjectHelp.cpp index 416bdd542ba..98fe2ad58c2 100644 --- a/lldb/source/Commands/CommandObjectHelp.cpp +++ b/lldb/source/Commands/CommandObjectHelp.cpp @@ -146,6 +146,10 @@ CommandObjectHelp::Execute (Args& command, CommandReturnObject &result) && (strlen (long_help) > 0)) output_strm.Printf ("\n%s", long_help); // Mark this help command with a success status. + if (sub_cmd_obj->WantsRawCommandString()) + { + m_interpreter.OutputFormattedHelpText (output_strm, "", "", "\nIMPORTANT NOTE: Because this command takes 'raw' input, if you use any command options you must use ' -- ' between the end of the command options and the beginning of the raw input.", 1); + } result.SetStatus (eReturnStatusSuccessFinishNoResult); } else if (sub_cmd_obj->IsMultiwordObject()) |