Bug 10683

Summary: Optionally drop "member access control" level in MI -var-list-children output
Product: gdb Reporter: Andre' <andre.poenitz>
Component: varobjAssignee: Not yet assigned to anyone <unassigned>
Status: NEW ---    
Severity: enhancement CC: dodji, gdb-prs, simark, tromey, tromey
Priority: P2 Keywords: mi3
Version: unknown   
Target Milestone: 6.8   
Host: Target:
Build: Last reconfirmed: 2011-11-10 00:00:00

Description Andre' 2009-09-22 07:07:27 UTC
It would be nice if there were a way to (optionally) drop the artificial
'public/protected/private' levels that -var-list-children creates, as this would
help to reduce the number of round trips between a frontend and gdb.

One solution might be a new option:

  -var-list-children --all-values --no-member-access  <varname>

The left out values might even get re-added to the individual items such that
the result looks like

 
^done,numchild="1",children=[child={name="foo",exp="foo",numchild="1",value="{...}",type="Foo",access="protected"}]
Comment 1 Tom Tromey 2023-08-31 17:22:24 UTC
FWIW I have never understood this decision in MI.
It seems plainly bad.  If the access control is interesting,
it ought to be an attribute of the field, not some kind
of synthetic field-like thing.