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] Fix DW_AT_lower_bound DWARF-4+ defaults


On Thu, 26 Apr 2012 17:29:36 +0200, Tom Tromey wrote:
> I looked at the DWARF 3 spec and it says:
> 
>     If the lower bound value is missing, the value is assumed to be a
>     language-dependent default constant. The default lower bound value for C
>     or C++ is 0. For Fortran, it is 1.
> 
> So it seems wrong to complain here;

All of DWARF 2, 3 and 4 have there also the paragraph:
	No other default lower bound values are currently defined.

Which makes the complaint IMNSHO right.


> defaults is informative, not exhaustive, and we should just pick a
> reasonable default and not complain.

Some reasonable default is picked, maybe we could discuss if this fallback
could be improved but I find 0 to be good enough for invalid DWARF input.


Thanks,
Jan


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