[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Mixed C/C++ bug - g++-3.2_3.2.1-0pre4 (unstable)



While 3.2.1-0pre3 works fine, 3.2.1-0pre4 fails.
Given input file test.cpp:

#include <stdio.h>
#include <iostream>
using std::cerr;
using std::endl;

int main()
{
  fprintf(stderr, "test\n");
  fflush( stderr );
  cerr << "test" << endl;
}



$ g++ test.cpp -o test
In file included from test.cpp:1:
/usr/lib/gcc-lib/i386-linux/3.2.1/include/stdio.h:55: syntax error before
`
   typedef'
/usr/lib/gcc-lib/i386-linux/3.2.1/include/stdio.h:60: `FILE' was not
declared
   in this scope
/usr/lib/gcc-lib/i386-linux/3.2.1/include/stdio.h:71: parse error before `
   typedef'
In file included from test.cpp:1:
/usr/lib/gcc-lib/i386-linux/3.2.1/include/stdio.h:97: syntax error before
`
   typedef'
/usr/lib/gcc-lib/i386-linux/3.2.1/include/stdio.h:103: syntax error before
`
   typedef'
In file included from test.cpp:1:
[...]



Reply to: