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 0/2] Make use of gdb::options for info variabels|functions|args|locals


>>>>> "Andrew" == Andrew Burgess <andrew.burgess@embecosm.com> writes:

Andrew> +void
Andrew> +info_print_command_completer (struct cmd_list_element *ignore,
Andrew> +			      completion_tracker &tracker,
Andrew> +			      const char *text, const char * /* word */)
Andrew> +{
Andrew> +  const auto group
Andrew> +    = make_info_print_options_def_group (nullptr);
Andrew> +  if (gdb::option::complete_options
Andrew> +      (tracker, &text, gdb::option::PROCESS_OPTIONS_UNKNOWN_IS_OPERAND, group))
Andrew> +    return;
Andrew> +
Andrew> +  const char *word = advance_to_expression_complete_word_point (tracker, text);
Andrew> +  symbol_completer (ignore, tracker, text, word);
Andrew> +  return;
Andrew> +}

I didn't really read the patch but this unnecessary return popped out at me.
I think gdb style is not to do this.

Tom


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