This is the mail archive of the gdb@sources.redhat.com 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]

Re: RFC: UI_OUT activation time


Fernando,

As one of the groups using the UI_OUT feature, I naturally think this is a great idea!  But even without the self interest, I think that this is a good idea.  The UI_OUT printers are much better than relying on the printf_* routines, since the UI_OUT mode preserves the knowledge of the significance of each bit in the output, whereas the printf_* routines force anyone who wants to use gdb output to reparse the results - basically throwing away information, then trying to reconstruct it later on.  

It is silly to support two output printing methods, gdb is complicated enough already, we don't need to add complexity...

Jim

On Thursday, November 16, 2000, at 06:37 AM, Fernando Nasser wrote:

> I am aware of several projects on the net that rely on the output
> produced through the new ui_out output functions.
> The separation between the CLI and libgdb also relies on that.
> 
> Currently, the old version of the code (using the ?printf_* family of
> functions) is still there, on a "ifdef", but it is still the default.
> One has to explicitly build with UI_OUT defined to use the new code.
> 
> The people who are working on the projects above (that includes me) are
> concerned that the default has not yet been changed.  This is probably
> also delaying the availability of script languages in GDB.
> 
> Having both codes make the sources hard to read because of the ifdefs.
> Furthermore, we cannot write code that assumes that ui_out is present
> because GDB can still be configured without it.  I have recently received
> a patch which would change only the old code (as it is the active one)
> without changing the new ui_out based version. And the ui_out code is
> not been tested at large.
> 
> I propose (and I will submit a patch) to make the ui_out code the default
> effective immediately, and the complete elimination of the old style code
> from the sources before 5.1.
> 
> 
> -- 
> Fernando Nasser
> Red Hat Canada Ltd.                     E-Mail:  fnasser@redhat.com
> 2323 Yonge Street, Suite #300
> Toronto, Ontario   M4P 2C9

--
Jim Ingham                                   jingham@apple.com
Developer Tools - gdb
Apple Computer

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