This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC 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: [PATCH] Additional features for -fms-extensions



On Oct 30, 2004, at 12:39 PM, Schönbeck, Andreas wrote:


/*
  Results:

GCC:
test4.cxx:xx: error: 'void test()' was declared 'extern' and later 'static'
*/GCC (3.3):


class A
{
  friend void test();
};

static void test()
{
}

int main()
{
  test();
  return 0;
}


The reason why this is an error and not a warning is because it will create “wrong” code and do what you expect in 3.4 and above.

-- Pinski


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