简体   繁体   English

Visual Studio 2008中是否有2003兼容性设置(编译器兼容性,不是项目/解决方案文件)

[英]Is there a 2003 compatibility setting in Visual Studio 2008 (compiler compatibility, not project / solution files)

I have a Visual Studio 2003 solution that I've opened with VS2008, and it converted successfully. 我有一个随VS2008打开的Visual Studio 2003解决方案,它转换成功。 However, it won't build because the code contains some things that were acceptable under Visual Studio 2003, but simply don't fly under Visual Studio 2008. Changing the code would be really difficult in my particular situation. 但是,由于代码中包含Visual Studio 2003可以接受的某些内容,但根本无法在Visual Studio 2008下运行,因此无法构建代码。在我的特定情况下,更改代码确实很困难。 Is there a flag or something that I can set which would use 2003-compatible compilation? 是否有一个我可以设置的标志或可以使用2003兼容编译的标志?

Cheers, Frank 干杯,弗兰克

The default warning level in VS2008 is -W3. VS2008中的默认警告级别为-W3。 Change the warning level to -W2 (more forgiving). 将警告级别更改为-W2(更多的宽容)。 I had the same issue moving from VC6 to VS2008. 从VC6到VS2008,我遇到了同样的问题。

Right-click on the project; 右键单击该项目; select Properties; 选择属性; Warning Level is set in the Compiler section. 警告级别在“编译器”部分中设置。

There is not a compatibility switch. 没有兼容性开关。 You'll have to install VS2k3 if you can't update the source code. 如果无法更新源代码,则必须安装VS2k3。

绝对您错过了somthing.othetwise vs2008不支持任何此类清算。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM