problems with iso restrict

Mark Mitchell mark@markmitchell.com
Fri Dec 4 11:07:00 GMT 1998


>>>>> "Jeffrey" == Jeffrey A Law <law@hurl.cygnus.com> writes:

    Jeffrey> Seems to me like "restrict" should not be a reserved word
    Jeffrey> unless we are in c9x mode.

Right.  I have no idea how Ulrich and crew have set up the various
-std= options and what the defaults are.  `restrict' should not be
reserved if flag_isoc9x is not set:

  if (flag_traditional)
    {
      UNSET_RESERVED_WORD ("const");
      UNSET_RESERVED_WORD ("restrict");
      UNSET_RESERVED_WORD ("volatile");
      UNSET_RESERVED_WORD ("typeof");
      UNSET_RESERVED_WORD ("signed");
      UNSET_RESERVED_WORD ("inline");
      UNSET_RESERVED_WORD ("iterator");
      UNSET_RESERVED_WORD ("complex");
    }
  else if (!flag_isoc9x)
    UNSET_RESERVED_WORD ("restrict");

Since flag_isoc9x is initialized to zero, and only set if
-flang-isoc9x is passed to cc1, someone must be passing it to cc1.

This doesn't happen for me with my current cc1, which is a couple of
days old.  In other words, I cannot even reproduce the problem.

-- 
Mark Mitchell 			mark@markmitchell.com
Mark Mitchell Consulting	http://www.markmitchell.com



More information about the Gcc-bugs mailing list