llvm-project/lldb/source
Stefan Granitz c678ed774d Add EchoCommentCommands to CommandInterpreterRunOptions in addition to the existing EchoCommands and expose both as interpreter settings.
Summary:
Add settings to control command echoing:
```
(lldb) settings set interpreter.echo-commands true
(lldb) settings set interpreter.echo-comment-commands true
```

Both settings default to true, which keeps LLDB's existing behavior in non-interactive mode (echo all command inputs to the output).

So far the only way to change this behavior was the `--source-quietly` flag, which disables all output including evaluation results.
Now `echo-commands` allows to turn off echoing for commands, while evaluation results are still printed. No effect if `--source-quietly` was present.
`echo-comment-commands` allows to turn off echoing for commands in case they are pure comment lines. No effect if `echo-commands` is false.

Note that the behavior does not change immediately! The new settings take effect only with the next command source.

LLDB lit test are the main motivation for this feature. So far incoming `#CHECK` line have always been echoed to the output and so they could never fail. Now we can disable it in lit-lldb-init.
Todos: Finish test for this feature. Add to lit-lldb-init. Check for failing lit tests.

Reviewers: aprantl, jasonmolenda, JDevlieghere

Subscribers: friss, lldb-commits

Differential Revision: https://reviews.llvm.org/D52788

llvm-svn: 343859
2018-10-05 16:49:47 +00:00
..
API Add EchoCommentCommands to CommandInterpreterRunOptions in addition to the existing EchoCommands and expose both as interpreter settings. 2018-10-05 16:49:47 +00:00
Breakpoint llvm::sort(C.begin(), C.end(), ...) -> llvm::sort(C, ...) 2018-09-27 03:35:05 +00:00
Commands Add EchoCommentCommands to CommandInterpreterRunOptions in addition to the existing EchoCommands and expose both as interpreter settings. 2018-10-05 16:49:47 +00:00
Core Escape newlines in default disassembly format. 2018-10-01 13:20:15 +00:00
DataFormatters Reflow paragraphs in comments. 2018-04-30 16:49:04 +00:00
Expression Revert "[IRInterpreter] Minor cleanups, add comments. NFCI." 2018-09-17 18:14:38 +00:00
Host Fix typos. 2018-10-04 22:33:39 +00:00
Initialization Move pretty stack trace printer into driver. 2018-07-17 10:04:19 +00:00
Interpreter Add EchoCommentCommands to CommandInterpreterRunOptions in addition to the existing EchoCommands and expose both as interpreter settings. 2018-10-05 16:49:47 +00:00
Plugins Fix typos. 2018-10-04 22:33:39 +00:00
Symbol [lldb] Start a new line for the next output if there are no symbols in the current symtab 2018-10-01 17:08:51 +00:00
Target Replace pointer to C-array of PropertyDefinition with llvm::ArrayRef 2018-09-27 07:11:58 +00:00
Utility Add support for descriptions with command completions. 2018-09-13 21:26:00 +00:00
CMakeLists.txt Remove Plugins/Process/POSIX from include_directories 2017-04-11 12:26:25 +00:00
lldb.cpp Run clang-format on lldb.cpp 2017-11-02 16:56:52 +00:00