Ê
Êé´ôÅí
today I forgot to include some header,then I found the error message by the compiler is quite strange.
so I want to know exactly the inner details of the compiler impletation,if possible.
and I want to know what does the standard say about this situation.
here is the code just to demonstrate the error.
int main()
{
new int; // this is OK
new someClass; // yeah,I know this is wrong because someClass is not declared.
return 0;
}
the Visual C++ 6.0 compiler said:
D:\test1\test1.cpp(12) : error C2061: syntax error : identifier 'someClass'
D:\test1\test1.cpp(15) : error C2143: syntax error : missing ';' before '}'
D:\test1\test1.cpp(15) : error C2143: syntax error : missing ';' before '}'
....
D:\test1\test1.cpp(15) : fatal error C1003: error count exceeds 100; stopping compilation
where the "..." represent 97 messages of "error C2143: syntax error : missing ';' before '}' "
so I guess something made the compiler drop into a infinitive recursion .
but I dont know why.
please tell me if you just know the reason.
if you dont have time,just ignore this.
thanks very much.
so I want to know exactly the inner details of the compiler impletation,if possible.
and I want to know what does the standard say about this situation.
here is the code just to demonstrate the error.
int main()
{
new int; // this is OK
new someClass; // yeah,I know this is wrong because someClass is not declared.
return 0;
}
the Visual C++ 6.0 compiler said:
D:\test1\test1.cpp(12) : error C2061: syntax error : identifier 'someClass'
D:\test1\test1.cpp(15) : error C2143: syntax error : missing ';' before '}'
D:\test1\test1.cpp(15) : error C2143: syntax error : missing ';' before '}'
....
D:\test1\test1.cpp(15) : fatal error C1003: error count exceeds 100; stopping compilation
where the "..." represent 97 messages of "error C2143: syntax error : missing ';' before '}' "
so I guess something made the compiler drop into a infinitive recursion .
but I dont know why.
please tell me if you just know the reason.
if you dont have time,just ignore this.
thanks very much.