* How to get raw data with MI when pretty printing is enabled ? @ 2010-06-19 8:32 Sébastien Granjoux 2010-06-19 8:44 ` asmwarrior 2010-06-21 20:03 ` Tom Tromey 0 siblings, 2 replies; 8+ messages in thread From: Sébastien Granjoux @ 2010-06-19 8:32 UTC (permalink / raw) To: gdb Hi, The pretty printing display is easier to read. But if the data are wrong it can be useful to see exactly what is the content of a variable. Is it possible get this after using -enable-pretty-printing ? As pretty-printing can change the number of children, I suppose it cannot be done using -var-set-format or something similar. But I think it would be useful if it is possible to create a new variable object which is not using pretty printer. Regards, Sébastien ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: How to get raw data with MI when pretty printing is enabled ? 2010-06-19 8:32 How to get raw data with MI when pretty printing is enabled ? Sébastien Granjoux @ 2010-06-19 8:44 ` asmwarrior 2010-06-21 20:03 ` Tom Tromey 1 sibling, 0 replies; 8+ messages in thread From: asmwarrior @ 2010-06-19 8:44 UTC (permalink / raw) To: Sébastien Granjoux; +Cc: gdb On 2010-6-19 16:32, Sébastien Granjoux wrote: > Hi, > > The pretty printing display is easier to read. But if the data are > wrong it can be useful to see exactly what is the content of a > variable. Is it possible get this after using -enable-pretty-printing ? > > As pretty-printing can change the number of children, I suppose it > cannot be done using -var-set-format or something similar. But I think > it would be useful if it is possible to create a new variable object > which is not using pretty printer. > > Regards, > > Sébastien If you are not in MI mode, the command is like: print /r YourVariableName asmwarrior ollydbg from codeblocks' forum ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: How to get raw data with MI when pretty printing is enabled ? 2010-06-19 8:32 How to get raw data with MI when pretty printing is enabled ? Sébastien Granjoux 2010-06-19 8:44 ` asmwarrior @ 2010-06-21 20:03 ` Tom Tromey 2010-06-21 20:18 ` Sébastien Granjoux 2010-06-22 6:40 ` -var-set-visualizer to dynamically switch pretty print on and off? Elmenthaler, Jens 1 sibling, 2 replies; 8+ messages in thread From: Tom Tromey @ 2010-06-21 20:03 UTC (permalink / raw) To: Sébastien Granjoux; +Cc: gdb >>>>> "Sébastien" == Sébastien Granjoux <sebastien.granjoux@free.fr> writes: Sébastien> As pretty-printing can change the number of children, I Sébastien> suppose it cannot be done using -var-set-format or something Sébastien> similar. But I think it would be useful if it is possible to Sébastien> create a new variable object which is not using pretty Sébastien> printer. All the new features here are fully documented. If you look through the MI part of the manual and find that something is not there, or is incorrect or unclear, please email or file a bug report so we can fix it. You can use -var-set-visualizer to disable pretty-printing of a given varobj. Tom ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: How to get raw data with MI when pretty printing is enabled ? 2010-06-21 20:03 ` Tom Tromey @ 2010-06-21 20:18 ` Sébastien Granjoux 2010-06-21 21:24 ` Tom Tromey 2010-06-22 6:40 ` -var-set-visualizer to dynamically switch pretty print on and off? Elmenthaler, Jens 1 sibling, 1 reply; 8+ messages in thread From: Sébastien Granjoux @ 2010-06-21 20:18 UTC (permalink / raw) To: tromey; +Cc: Sébastien Granjoux, gdb Hi Tom, Le 21/06/2010 22:03, Tom Tromey a écrit : > You can use -var-set-visualizer to disable pretty-printing of a given > varobj. I have tried but it doesn't work. -var-create - * str_list ^done,name="var1",numchild="3",value="0x9ae2c90",type="GList *",thread-id="1",has_more="0" (gdb) -enable-pretty-printing ^done (gdb) -var-create - * str_list ^done,name="var2",numchild="0",value="{...}",type="GList *",thread-id="1",displayhint="array",dynamic="1",has_more="1" (gdb) -var-evaluate-expression var2 ^done,value="{...}" (gdb) -var-evaluate-expression var1 ^done,value="0x9ae2c90" (gdb) -var-set-visualizer var2 None ^done (gdb) -var-evaluate-expression var2 ^done,value="{...}" (gdb) I would expect value="0x9ae2c90" for the last command. Then, I have use gdb version 7.0.50.20091001-cvs, perhaps it's working with the latest one. Regards, Sébastien ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: How to get raw data with MI when pretty printing is enabled ? 2010-06-21 20:18 ` Sébastien Granjoux @ 2010-06-21 21:24 ` Tom Tromey 2010-06-22 19:14 ` Sébastien Granjoux 0 siblings, 1 reply; 8+ messages in thread From: Tom Tromey @ 2010-06-21 21:24 UTC (permalink / raw) To: Sébastien Granjoux; +Cc: Sébastien Granjoux, gdb >>>>> "Sébastien" == Sébastien Granjoux <seb.sfo@free.fr> writes: Sébastien> -var-set-visualizer var2 None Sébastien> ^done Sébastien> (gdb) Sébastien> -var-evaluate-expression var2 Sébastien> ^done,value="{...}" Sébastien> (gdb) Sébastien> I would expect value="0x9ae2c90" for the last command. Then, I have Sébastien> use gdb version 7.0.50.20091001-cvs, perhaps it's working with the Sébastien> latest one. The test suite does a -var-update instead of -var-evaluate-expression. Could you try that instead? I'm not completely sure if the above is intended to work or not. Please file a bug report, in case it is supposed to. thanks, Tom ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: How to get raw data with MI when pretty printing is enabled ? 2010-06-21 21:24 ` Tom Tromey @ 2010-06-22 19:14 ` Sébastien Granjoux 0 siblings, 0 replies; 8+ messages in thread From: Sébastien Granjoux @ 2010-06-22 19:14 UTC (permalink / raw) To: tromey; +Cc: gdb Hi, Le 21/06/2010 23:24, Tom Tromey a écrit : > The test suite does a -var-update instead of -var-evaluate-expression. > Could you try that instead? Yes, it's working then. -var-list-children is working as expected too. Setting the visualizer to None, remove the pretty printer, while setting to gdb.default_visualizer restore it. > I'm not completely sure if the above is intended to work or not. > Please file a bug report, in case it is supposed to. I don't know neither. I have filled a bug report http://sourceware.org/bugzilla/show_bug.cgi?id=11738 Regards, Sébastien ^ permalink raw reply [flat|nested] 8+ messages in thread
* -var-set-visualizer to dynamically switch pretty print on and off? 2010-06-21 20:03 ` Tom Tromey 2010-06-21 20:18 ` Sébastien Granjoux @ 2010-06-22 6:40 ` Elmenthaler, Jens 2010-06-22 15:42 ` Tom Tromey 1 sibling, 1 reply; 8+ messages in thread From: Elmenthaler, Jens @ 2010-06-22 6:40 UTC (permalink / raw) Cc: gdb > You can use -var-set-visualizer to disable pretty-printing of a given > varobj. > > Tom Does that mean I can use -var-set-visualizer to dynamically switch between pretty printers on and off during a debug session, and this even individually for each varobj? That would be a nice feature! Jens. ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: -var-set-visualizer to dynamically switch pretty print on and off? 2010-06-22 6:40 ` -var-set-visualizer to dynamically switch pretty print on and off? Elmenthaler, Jens @ 2010-06-22 15:42 ` Tom Tromey 0 siblings, 0 replies; 8+ messages in thread From: Tom Tromey @ 2010-06-22 15:42 UTC (permalink / raw) To: Elmenthaler, Jens; +Cc: gdb >>>>> "Jens" == Elmenthaler, Jens <jens.elmenthaler@verigy.com> writes: Tom> You can use -var-set-visualizer to disable pretty-printing of a given Tom> varobj. Jens> Does that mean I can use -var-set-visualizer to dynamically switch Jens> between pretty printers on and off during a debug session, and Jens> this even individually for each varobj? That would be a nice Jens> feature! Yes. Dynamic varobjs have other nice features, too -- you can lazily fetch the children. It is all in the manual... let us know if it is unclear in some way. Tom ^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2010-06-22 19:14 UTC | newest] Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2010-06-19 8:32 How to get raw data with MI when pretty printing is enabled ? Sébastien Granjoux 2010-06-19 8:44 ` asmwarrior 2010-06-21 20:03 ` Tom Tromey 2010-06-21 20:18 ` Sébastien Granjoux 2010-06-21 21:24 ` Tom Tromey 2010-06-22 19:14 ` Sébastien Granjoux 2010-06-22 6:40 ` -var-set-visualizer to dynamically switch pretty print on and off? Elmenthaler, Jens 2010-06-22 15:42 ` Tom Tromey
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox