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: [RFA/commit] (Ada) fix GDB crash printing packed array


> Joel>   (1) Forcing the lookup into language_c currently does not affect
> Joel>       how symbol matching is done anymore, because we look at the symbol's
> Joel>       language to determine which kind of matching should be done;
> 
> There's also this code in get_symbol_name_matcher:
> 
>   /* If currently in Ada mode, and the lookup name is wrapped in
>      '<...>', hijack all symbol name comparisons using the Ada
>      matcher, which handles the verbatim matching.  */
>   if (current_language->la_language == language_ada
>       && lookup_name.ada ().verbatim_p ())
>     return current_language->la_get_symbol_name_matcher (lookup_name);
> 
> I don't know if this could be removed, but if so it would be better to
> do so.

I was absolutely certain, looking at the new code, that we could
remove this, but unfortunately, it turns out there is a regression.

Before removing:

    (gdb) p <MixedCaseFunc>
    $1 = void^M

After:

    (gdb) p <MixedCaseFunc>
    $1 = {<text variable, no debug info>} 0x4029c6 <MixedCaseFunc>

This tells me that the function symbol wasn't found (in the debuging
info), so we used the minsym instead.  Not sure if this is because
the verbatim_p flag might be missing, or because of something else.

We'll put this on our list of things to investigate, one of these days.

> The patch looks fine to me.

Thanks! Now pushed to master.

-- 
Joel


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