views:

136

answers:

1

Does C++0x mode in VC++ 2010 has an off switch? I am working on a project that supposed to compile on non 0x compilers, and therefore I want to compile against the current standard. (Even if non of the new features are being used directly, there are still subtleties that makes C++0x more premissive).

The closest switch I found was Configuration Properties -> C/C++ -> Language -> Disable Language Extensions but that's not it.

+5  A: 

No, language extensions are typically non-standard vendor specific additions.

C++0X features: There is no direct way to switch off these features. One workaround is to not use them. However, note that there will still be marked difference in performance across versions of VC runtime. VC10 implements move semantics and the standard library (std::string for example) uses these features generously.

A reasonable compromise in my opinion is to switch back to VS2008. Recent VS versions have been notoriously buggy (so far, in my experience) and have never worked the way they should without a Service Pack. VS2008 is pretty stable now, without any of those C++0x features and ought to fit your bill.

dirkgently
You can also switch back to using the VS2008 compiler in the VS2010 IDE as well in the project settings.
Andy