Re: [Lldb-commits] [PATCH] D116788: [lldb] Set result error state in 'frame variable'

2022-01-11 Thread Jim Ingham via lldb-commits
Indeed not. Since you can get everything you would need straightforwardly using SBFrame::FindVariables, there’s no pressing need to give another way to do it using HandleCommand. Jim > On Jan 11, 2022, at 2:02 PM, Dave Lee via Phabricator > wrote: > > kastiglione added a comment. > >> if I

[Lldb-commits] [PATCH] D116788: [lldb] Set result error state in 'frame variable'

2022-01-11 Thread Dave Lee via Phabricator via lldb-commits
kastiglione added a comment. > if I run “frame var” from HandleCommand in a script, with this change I can’t > rely on the command status to tell whether the command output had anything > interesting in it. That seems awkward. This could be resolved by introducing a new enum value to indicate p

Re: [Lldb-commits] [PATCH] D116788: [lldb] Set result error state in 'frame variable'

2022-01-10 Thread Jim Ingham via lldb-commits
I agree that if we are going to start putting in errors for not finding listed arguments to “frame var” we should do it consistently, and Greg’s list seems good - along with the error “No debug info” when “frame var” is run in a frame w/o debug info or recognizers. The one thing that bothers me

[Lldb-commits] [PATCH] D116788: [lldb] Set result error state in 'frame variable'

2022-01-10 Thread Dave Lee via Phabricator via lldb-commits
kastiglione added a comment. > Let me know your thoughts as mine are just my initial thoughts after thinking > about things a bit more. For most of what you said, I was thinking the same. The only place where I wasn't as sure about (regex), I was on the fence. Your cases and arguments all seem

[Lldb-commits] [PATCH] D116788: [lldb] Set result error state in 'frame variable'

2022-01-10 Thread Greg Clayton via Phabricator via lldb-commits
clayborg added a comment. In D116788#3232105 , @kastiglione wrote: > In D116788#3231612 , @clayborg > wrote: > >> I would vote that if any argument or option is specified, and results in >> something not being

[Lldb-commits] [PATCH] D116788: [lldb] Set result error state in 'frame variable'

2022-01-10 Thread Dave Lee via Phabricator via lldb-commits
kastiglione added a comment. In D116788#3231612 , @clayborg wrote: > I would vote that if any argument or option is specified, and results in > something not being found, that an error be returned. Is this in response to my question about regexes? It se

[Lldb-commits] [PATCH] D116788: [lldb] Set result error state in 'frame variable'

2022-01-10 Thread Greg Clayton via Phabricator via lldb-commits
clayborg added a comment. I would vote that if any argument or option is specified, and results in something not being found, that an error be returned. The error state doesn't do anything for the user on the command line, but it is nice to know that something failed to produce a result due to

[Lldb-commits] [PATCH] D116788: [lldb] Set result error state in 'frame variable'

2022-01-08 Thread Dave Lee via Phabricator via lldb-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG2c7d10c41278: [lldb] Set result error state in 'frame variable' (authored by kastiglione). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116788/new/ https:/

[Lldb-commits] [PATCH] D116788: [lldb] Set result error state in 'frame variable'

2022-01-07 Thread Jonas Devlieghere via Phabricator via lldb-commits
JDevlieghere accepted this revision. JDevlieghere added inline comments. This revision is now accepted and ready to land. Comment at: lldb/source/Commands/CommandObjectFrame.cpp:560-563 } else if (num_matches == 0) { -result.GetErrorStream().Printf(

[Lldb-commits] [PATCH] D116788: [lldb] Set result error state in 'frame variable'

2022-01-06 Thread Dave Lee via Phabricator via lldb-commits
kastiglione added a subscriber: jingham. kastiglione added inline comments. Comment at: lldb/source/Commands/CommandObjectFrame.cpp:560-563 } else if (num_matches == 0) { -result.GetErrorStream().Printf("error: no variables matched " -

[Lldb-commits] [PATCH] D116788: [lldb] Set result error state in 'frame variable'

2022-01-06 Thread Dave Lee via Phabricator via lldb-commits
kastiglione added inline comments. Comment at: lldb/source/Commands/CommandObjectFrame.cpp:560-563 } else if (num_matches == 0) { -result.GetErrorStream().Printf("error: no variables matched " - "the reg

[Lldb-commits] [PATCH] D116788: [lldb] Set result error state in 'frame variable'

2022-01-06 Thread Dave Lee via Phabricator via lldb-commits
kastiglione updated this revision to Diff 398040. kastiglione added a comment. s/warning/error Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116788/new/ https://reviews.llvm.org/D116788 Files: lldb/source/Commands/CommandObjectFrame.cpp Index:

[Lldb-commits] [PATCH] D116788: [lldb] Set result error state in 'frame variable'

2022-01-06 Thread Dave Lee via Phabricator via lldb-commits
kastiglione created this revision. kastiglione added reviewers: JDevlieghere, clayborg. kastiglione requested review of this revision. Herald added a project: LLDB. Herald added a subscriber: lldb-commits. Ensure that errors in `frame variable` are reflected in result object. The statistics for `