This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Variable objects: references formatting


On 5/3/06, Nick Roberts <nickrob@snap.net.nz> wrote:
 > The patch is against an older version of varobj.c, and does seem to be
 > cut from a larger patch, but it applies, and given the surrounding
 > code in c_value_of_variable, and the behavior of c_val_print, the
 > general sense of the change seems correct.  Have you tried creating
 > varobjs for values that are references to structs and displaying them,
 > which I think is the case actually being addressed?

OK, if its a patch for -var-valuate-expression then perhaps the BOGUS
comment could be removed as it seems to address this issue.

I read the "BOGUS" comment as referring to the fact that we have to specially trap structs and unions, instead of simply passing everything through common_val_print. I don't think this patch affects that "bogusness"; it just makes the workaround work better.

(Are there any cases where common_val_print (and thus c_val_print)
prints the "{...}" we need automatically for us?  Or is this code the
sole source of that behavior?)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]