【VC++】如何解决unexpected end of file while looking for precompiled header directive

来源:互联网 发布:python 最大回撤 编辑:程序博客网 时间:2024/05/29 07:05
 在调试程序是发现错误:fatal error C1010: unexpected end of file while looking for precompiled header directive

分析:工程头文件处理的错误。

解决办法:

1、右键点工程名,选设置,然后选c/c++属性页,再选catagory选单中选 precompiled header ,将选项置成no use 或者autometic

2、如果使用的是Win32工程,可能就是错误文件没有包含:#include "stdafx.h"  ,添加该包含即可。