On Wed, 17 Oct 2012, Manuel L?pez-Ib??ez wrote: > This patch changes most trivial cases to use the new (Lang)EnabledBy. > > Bootstrapped and regression tested on x86_64-linux-gnu. OK? > > 2012-10-17 Manuel L?pez-Ib??ez <m...@gcc.gnu.org> > > PR c/53063 > PR c/40989 > c-family/ > * c.opt (Waddress,Wchar-subscripts,Wsign-conversion,Wimplicit, > Wimplicit-function-declaration,Wimplicit-int,Wsizeof-pointer-memaccess, > Wnarrowing,Wparentheses,Wpointer-sign,Wreturn-type,Wsequence-point, > Wsign-compare,Wuninitialized,Wmaybe-uninitialized,Wunused, > Wvolatile-register-var): Add LangEnabledBy or EnabledBy. > * c-opts.c (c_common_handle_option): Remove explicit handling from > here. > (c_common_post_options): Likewise. > gcc/ > * opts.c (finish_options): Remove explicit handling from here.
OK. > Not sure how to encode these dependencies. Ideas? No specific suggestions here. If a particular case isn't common enough to have a .opt mechanism for it, then in principle the use of the _set structures tracking what was explicitly set could replace the use of -1 initializers. But since the _set structures generally correspond to what was set directly, whereas implicit setting by another option also replaces the -1 value, this might only work given the extension of _set structures to record the distance between the option passed by the user and the one set, not just whether each option was set directly. -- Joseph S. Myers jos...@codesourcery.com