This is an archive of the discontinued LLVM Phabricator instance.

[lldb] Specify aguments of `image list`
ClosedPublic

Authored by kastiglione on May 6 2022, 7:08 PM.

Details

Summary

Register positional argument details in CommandObjectTargetModulesList.

I recently learned that image list takes a module name, but the help info
does not indicate this. With this change, help image list will show that it
accepts zero or more module names.

This makes it easier to get info about specific modules, without having to
find/grep through the full image list.

Diff Detail

Event Timeline

kastiglione created this revision.May 6 2022, 7:08 PM
Herald added a project: Restricted Project. · View Herald TranscriptMay 6 2022, 7:08 PM
kastiglione requested review of this revision.May 6 2022, 7:08 PM
Herald added a project: Restricted Project. · View Herald TranscriptMay 6 2022, 7:08 PM

Can you add a test for the help output to lldb/test/API/commands/help/TestHelp.py ? Just the one line that includes the argument list is fine.

Also I see that we don't test this part of the command at all. Not an issue for this change (I assume it is working for you right now otherwise you wouldn't be doing this) but coverage would be welcome.

add to TestHelp.py

@DavidSpickett I might do some follow up work, if so I will add coverage then.

LGTM

PS: Small typo in your summary: s/abot/about/.

DavidSpickett accepted this revision.May 16 2022, 4:04 AM
This revision is now accepted and ready to land.May 16 2022, 4:04 AM
kastiglione edited the summary of this revision. (Show Details)May 23 2022, 10:59 AM
This revision was automatically updated to reflect the committed changes.