Forward referencing with typedef

Jonathan Wakely jwakely.gcc@gmail.com
Sat Dec 10 13:41:00 GMT 2011


On 10 December 2011 04:15, Divyesh wrote:
>
> But it is interesting to see that g++ does compile this sample of code
>
> So I am confused now as there are inconsistencies between gcc and g++

It's not inconsistent. G++ treats the file as C++ code by default, and
your program is valid in C++, but not in C.



More information about the Gcc-help mailing list