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 C `extern' shadowing in a local block


On Thu, 26 Mar 2009 22:21:28 +0100, Jan Kratochvil wrote:
> fix GDB evaluation for:
> {
>   int var = 1;
>   {
>     extern int var;
> 
>     Access "var" at this point from GDB which must access the `extern' variable.
>   }
> }
> 
> Such code will still not work due to GCC PR debug/39563.  GCC may also fix it
> a way compatible with current GDB (`extern var' to be global and use
> DW_TAG_imported_declaration in the local block).  Still IMO a valid DWARF
> layout used in the attached .S testcase currently fails for GDB.

The patch provided for GCC (but still not checked-in) requires fixed GDB:
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39563#c5


Thanks,
Jan


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