[Lldb-commits] [lldb] [lldb-dap] Add an option to show function args in stack frames (PR #71843)
Greg Clayton via lldb-commits
lldb-commits at lists.llvm.org
Thu Nov 9 12:04:22 PST 2023
https://github.com/clayborg requested changes to this pull request.
So this hardcodes the frame display to only be the function name, or function name with args. Do we want to allow users to specify a frame format in the lldb-vscode settings? We could have two settings: one to enable the feature with something like `showFramesWithCustomFormat` and on that contains the format string like `customFrameFormat` which would default to `"${function.name-with-args}"`. Then users have complete control over how and what gets displayed. Some people might want to show the pc value and then the function name like:
```
"customFrameFormat": "${frame.pc} ${function.name-with-args}"
```
If we want this then we will want to modify the SBFrame changes to be something like:
```
SBError SBFrame::ApplyFormat(SBStream &output, const char *format_string);
```
We might even consider makding a `lldb::SBFormat` class that allows us to compile a format string into an object and then use it. If we do this then the API above will be:
```
SBError SBFrame::ApplyFormat(SBStream &output, lldb::SBFormat format);
```
https://github.com/llvm/llvm-project/pull/71843
More information about the lldb-commits
mailing list