编译错误中英文对照表?/p>
c++
?/p>
error count exceeds number; stopping compilation
中文对照:(编译错误)错误太多,停止编译
分析:修改之前的错误,再次编?/p>
unexpected end of file found
中文对照:(编译错误)文件未结束
分析:一个函数或者一个结构定义缺少?/p>
}
”、或者在一个函数调用或表达式中?/p>
号没有配对出现、或者注释符?/p>
/*
?/p>
*/
”不完整?/p>
Cannot open include file: 'xxx': No such file or directory
中文对照:(编译错误)无法打开头文?/p>
xxx
:没有这个文件或路径
分析:头文件不存在、或者头文件拼写错误、或者文件为只读
unable to recover from previous error(s); stopping compilation
中文对照:(编译错误)无法从之前的错误中恢复,停止编?/p>
分析:引起错误的原因很多,建议先修改之前的错?/p>
newline in constant
中文对照:(编译错误)常量中创建新行
分析:字符串常量多行书写
#include expected a filename, found 'identifier'
中文对照:(编译错误?/p>
#include
命令中需要文件名
分析:一般是头文件未用一对双引号或尖括号括起来,例如?/p>
#include stdio.h
?/p>
#define syntax
中文对照:(编译错误?/p>
#define
语法错误
分析:例如?/p>
#define
”后缺少宏名,例如?/p>
#define
?/p>
'xxx' : unexpected in macro definition
中文对照:(编译错误)宏定义时出现了意外?/p>
xxx
分析:宏定义时宏名与替换串之间应有空格,例如?/p>
#define TRUE"1"
?/p>
reuse of macro formal 'identifier'
中文对照:(编译错误)带参宏的形式参数重复使?/p>
分析:宏定义如有参数不能重名,例如?/p>
#define s(a,a) (a*a)
”中参数
a
重复
'character' : unexpected in macro formal parameter list
中文对照:(编译错误)带参宏的形式参数表中出现未知字?/p>
分析:例如?/p>
#define s(r|) r*r
”中参数多了一个字符?/p>
|
?/p>
preprocessor command must start as first nonwhite space
中文对照:(编译错误)预处理命令前面只允许空?/p>
分析:每一条预处理命令都应独占一行,不应出现其他非空格字?/p>
too many characters in constant
中文对照:(编译错误)常量中包含多个字符
分析:字符型常量的单引号中只能有一个字符,或是以?/p>
\
”开始的一个转义字符,
例如?/p>
char error = 'error';
?/p>
illegal escape sequence