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: [RFC]: Patch to support Fortran derived type - Revised


Hi Eli,

On Wed, 16 Nov 2005, Eli Zaretskii wrote:

> > Date: Wed, 16 Nov 2005 15:20:18 +0800 (CST)
> > From: Wu Zhou <woodzltc@cn.ibm.com>
> > cc: Thomas.Koenig@online.de
> > 
> > I revised the patch to add derived type support.  Now it can print 
> > the nested type such like this:
> > 
> > Type foo
> >     int4 :: a
> >     Type bar
> >         real :: b
> >     End Type bar :: x
> > End Type foo
> > 
> > It could also handle the member access like q%x%b.
> 
> Thanks.
> 
> > Any more place is needed to be improved, please let me know.
> 
> How about mentioning this in the manual?  It would be good to document
> how these values and types are printed, in case a user is not fluent
> with these f9x features.
> 
Thanks for your comments.  

Yes. I am thinking of adding these to gdb manual.  But I am not sure how 
to organize them. As you know, we already have three subsection: Fortran 
operators, Fortran defaults and special Fortran command.  Which section 
should this kind of text gets into?  Maybe special Fortran commands? 
But They are in fact common GDB command, only with somewhat different 
output format. Maybe it make sense to add another new section?  What do 
you think?

However I did added a few words in the Fortran operators section.  Here is 
the patch:

Index: gdb.texinfo
===================================================================
RCS file: /cvs/src/src/gdb/doc/gdb.texinfo,v
retrieving revision 1.296
diff -u -p -r1.296 gdb.texinfo
--- gdb.texinfo	20 Nov 2005 06:12:59 -0000	1.296
+++ gdb.texinfo	22 Nov 2005 07:05:01 -0000
@@ -9159,6 +9159,10 @@ of the second one.
 @item :
 The range operator.  Normally used in the form of array(low:high) to
 represent a section of array.
+
+@item %
+Fortran 90 and afterwards use this to access the members of derived
+type, which is also introduced after the Fortran 90.
 @end table
 
 @node Fortran Defaults


Regards
- Wu Zhou


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