Re: [MI] -stack-list-variables

Joel Brobecker
2009-09-19T15:45:45Z

Hi,

I just noticed a couple of things while glancing at the patch...

> +/* Print a list of the local variables (including arguments) for the
> + current frame. With argument of 0, print only the names, with
^ Space missing

> + argument of 1 print also the values. */

I also found the comment a little confusing. I would probably have
said that ARGC must be 1 or an error is thown, and to see
parse_print_values for a list of valid values for ARGV[0].
(there is no comment for parse_print_value, btw).

> + if (argc != 1)
> + error (_("Usage: PRINT_VALUES"));
> +
> + frame = get_selected_frame (NULL);
> +
> + list_args_or_locals (all, parse_print_values (argv[0]), frame);

The indentation of the last couple of statements is off by one.

--
Joel