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 03/40] Fix gdb.base/completion.exp with --target_board=dwarf4-gdb-index


On 07/13/2017 09:28 PM, Keith Seitz wrote:

> On 06/02/2017 05:22 AM, Pedro Alves wrote:
>> diff --git a/gdb/symtab.c b/gdb/symtab.c
>> index 22d81fa..69f3bc2 100644
>> --- a/gdb/symtab.c
>> +++ b/gdb/symtab.c
>> @@ -5385,7 +5385,6 @@ static VEC (char_ptr) *
>>  make_file_symbol_completion_list_1 (const char *text, const char *word,
>>  				    const char *srcfile)
>>  {
>> -  struct symtab *s;
>>    /* The symbol we are completing on.  Points in same buffer as text.  */
>>    const char *sym_text;
>>    /* Length of sym_text.  */
> 
> The comment for this function is (and also later when it is renamed to collect_file_symbol_completion_matches)
> 
> /* Like collect_symbol_completion_matches, but collects a list of
>    symbols defined in a source file FILE.  */
>                      ^^^^^^^^^^^^^^^^^^^^
> 
> I think that underlined bit should be updated to be a bit clearer. While it is pedantically correct, I think "in all source files named FILE" tells the reader of other important behavior/intent.

Agreed.  I did that change and pushed it in (with s/FILE/SRCFILE/
to match the actual parameter name while at it.)

Thanks,
Pedro Alves


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