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: [patch] DW_AT_byte_size for array type entries


> 2010-12-13  Ken Werner  <ken.werner@de.ibm.com>
> 
> 	* valops.c (value_one): Use get_array_bounds to compute the number
> 	of array elements instead of dividing the length of the array by the
> 	length of the element types.
> 	* valarith.c (value_complement, value_neg): Likewise.

This is OK.

As a followup patch, how about defining a new function `get_array_length'
next to get_array_bounds? That way, you  can factorize of this code that
keeps being repeated...

-- 
Joel


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