diff options
author | Kate Stone <katherine.stone@apple.com> | 2015-07-14 05:48:36 +0000 |
---|---|---|
committer | Kate Stone <katherine.stone@apple.com> | 2015-07-14 05:48:36 +0000 |
commit | ea671fbdffda6976607997eb2e5d796211cf5003 (patch) | |
tree | 24e6b00951c3ddccba9afad5f20faaf338d8ff81 /lldb/source/Commands/CommandObjectExpression.cpp | |
parent | 2ffb36e829f79d3660b7a2cf94a1746f62a81518 (diff) | |
download | bcm5719-llvm-ea671fbdffda6976607997eb2e5d796211cf5003.tar.gz bcm5719-llvm-ea671fbdffda6976607997eb2e5d796211cf5003.zip |
Fixed line wrapping for the "long help" content in LLDB commands. Content is now dynamically wrapped for the column width of the current terminal. Lines that begin with whitespace will be indented identically on subsequent lines to maintain formatting.
Existing commands supplying this type of help content have been reworked to take advantage of the changes. In addition to formatting changes, content was changes for accuracy and clarity purposes.
<rdar://problem/21269977>
llvm-svn: 242122
Diffstat (limited to 'lldb/source/Commands/CommandObjectExpression.cpp')
-rw-r--r-- | lldb/source/Commands/CommandObjectExpression.cpp | 62 |
1 files changed, 33 insertions, 29 deletions
diff --git a/lldb/source/Commands/CommandObjectExpression.cpp b/lldb/source/Commands/CommandObjectExpression.cpp index f4bb8fbac11..1be17a0cfdd 100644 --- a/lldb/source/Commands/CommandObjectExpression.cpp +++ b/lldb/source/Commands/CommandObjectExpression.cpp @@ -202,35 +202,39 @@ CommandObjectExpression::CommandObjectExpression (CommandInterpreter &interprete m_expr_line_count (0), m_expr_lines () { - SetHelpLong( -"Timeouts:\n\ - If the expression can be evaluated statically (without running code) then it will be.\n\ - Otherwise, by default the expression will run on the current thread with a short timeout:\n\ - currently .25 seconds. If it doesn't return in that time, the evaluation will be interrupted\n\ - and resumed with all threads running. You can use the -a option to disable retrying on all\n\ - threads. You can use the -t option to set a shorter timeout.\n\ -\n\ -User defined variables:\n\ - You can define your own variables for convenience or to be used in subsequent expressions.\n\ - You define them the same way you would define variables in C. If the first character of \n\ - your user defined variable is a $, then the variable's value will be available in future\n\ - expressions, otherwise it will just be available in the current expression.\n\ -\n\ -\n\ -Continuing evaluation after a breakpoint:\n\ - If the \"-i false\" option is used, and execution is interrupted by a breakpoint hit, once\n\ - you are done with your investigation, you can either remove the expression execution frames\n\ - from the stack with \"thread return -x\" or if you are still interested in the expression result\n\ - you can issue the \"continue\" command and the expression evaluation will complete and the\n\ - expression result will be available using the \"thread.completed-expression\" key in the thread\n\ - format.\n\ -\n\ -Examples: \n\ -\n\ - expr my_struct->a = my_array[3] \n\ - expr -f bin -- (index * 8) + 5 \n\ - expr unsigned int $foo = 5\n\ - expr char c[] = \"foo\"; c[0]\n"); + SetHelpLong( +R"( +Timeouts: + +)" " If the expression can be evaluated statically (without running code) then it will be. \ +Otherwise, by default the expression will run on the current thread with a short timeout: \ +currently .25 seconds. If it doesn't return in that time, the evaluation will be interrupted \ +and resumed with all threads running. You can use the -a option to disable retrying on all \ +threads. You can use the -t option to set a shorter timeout." R"( + +User defined variables: + +)" " You can define your own variables for convenience or to be used in subsequent expressions. \ +You define them the same way you would define variables in C. If the first character of \ +your user defined variable is a $, then the variable's value will be available in future \ +expressions, otherwise it will just be available in the current expression." R"( + +Continuing evaluation after a breakpoint: + +)" " If the \"-i false\" option is used, and execution is interrupted by a breakpoint hit, once \ +you are done with your investigation, you can either remove the expression execution frames \ +from the stack with \"thread return -x\" or if you are still interested in the expression result \ +you can issue the \"continue\" command and the expression evaluation will complete and the \ +expression result will be available using the \"thread.completed-expression\" key in the thread \ +format." R"( + +Examples: + + expr my_struct->a = my_array[3] + expr -f bin -- (index * 8) + 5 + expr unsigned int $foo = 5 + expr char c[] = \"foo\"; c[0])" + ); CommandArgumentEntry arg; CommandArgumentData expression_arg; |