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] Implement help/show values for 'set|show style'.


On Sat, 2019-01-12 at 10:17 -0700, Tom Tromey wrote:
> > > > > > "Philippe" == Philippe Waroquiers <philippe.waroquiers@skynet.be> writes:
> 
> Philippe> -Show the display intensity color for this property"),
> Philippe> +			_("Show the display intensity color for this property"),
> 
> Not your problem, but would you mind removing the "color" both here and
> from the "set" command help?  That's a copy-paste bug from my original
> patch.
> 
> Philippe> +#define STYLE_ADD_SETSHOW_COMMANDS(style, name, prefix_doc)	  \
> 
> It's more normal in gdb to use upper case for macro parameters.
> 
> I was hoping to avoid macros here but, meh, I guess it doesn't really
> matter much.
Yes, macros are not that nice.  My C++ knowledge being very minimal,
I did not directly see how to do that without macros.

> 
> Philippe> +  /* Return the 'set style NAME' command list, that can be used
> Philippe> +     to build a lambda DO_SET to call add_setshow_commands.  */
> Philippe> +  struct cmd_list_element *set_list () { return m_set_list; };
> Philippe> +
> Philippe> +  /* Same as SET_LIST but for the show command list.  */
> Philippe> +  struct cmd_list_element *show_list () { return m_show_list; };
> Philippe>  private:
> 
> I think a blank line before the "private:" would be good.
> 
> Thanks for doing this.  This is ok with these changes.
Pushed after doing the fixes above (macro params, fixing the 'color'
copy paste, and fixing another copy/paste error I did).

Thanks for the review

Philippe


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