This is the mail archive of the gdb-patches@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]
Other format: [Raw text]

Re: PATCH: Start Fortran support for variable objects.


On Sun, 3 Jul 2005, Daniel Jacobowitz wrote:

> On Fri, Jul 01, 2005 at 04:32:54PM +1200, Nick Roberts wrote:
> > So I should have done:
> > 
> > (top-gdb) p TYPE_LOW_BOUND(var->type->main_type->fields->type)
> > $1 = 1
> > (top-gdb) p TYPE_HIGH_BOUND(var->type->main_type->fields->type)
> > $2 = 4
> 
> Right - specifically, TYPE_LOW_BOUND (TYPE_INDEX_TYPE (var->type))
> is supposed to be the lower bound for an array.  Tricky.  It comes from
> read_subrange_type in dwarf2read.c for dwarf2.

Yes, it is tricky to me too.  Maybe it is better to change TYPE_INDEX_TYPE 
to TYPE_RANGE_TYPE.  This seems more obvious IMO.
 
- Wu Zhou


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