error C4430: missing type specifier int assumed. Note: C++ does not support defaultint 解决方法

在VS2008中生成时出错:error C4430: missing type specifier - int assumed. Note: C++ does not support default-int

这是因为在VC6中,如果没有显示的指定返回值类型,编译器将其视为默认整型。但是vs2005不支持默认整型。

解决方法如下:
打开:项目----项目属性----配置属性----C/C++----命令行,在附加选项那里添加/wd4430这个选项。

原文地址:https://www.cnblogs.com/cuteshongshong/p/C4430.html