https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90353

--- Comment #2 from Marc Glisse <glisse at gcc dot gnu.org> ---
(from https://stackoverflow.com/q/55977431/1918193)
Thanks.

except.c (initialize_handler_parm) says:

  /* Make sure we mark the catch param as used, otherwise we'll get a
     warning about an unused ((anonymous)).  */
  TREE_USED (decl) = 1;
  DECL_READ_P (decl) = 1;

But removing the TREE_USED line generates a nice "warning: unused variable
'k'". Running the testsuite with such a patch may help locate a testcase that
explains why this code is there.

Reply via email to