| title |
-Zc (Conformance) | Microsoft Docs |
| ms.custom |
|
| ms.date |
11/04/2016 |
| ms.reviewer |
|
| ms.suite |
|
| ms.technology |
|
| ms.tgt_pltfrm |
|
| ms.topic |
article |
| f1_keywords |
|
| dev_langs |
|
| helpviewer_keywords |
/Zc compiler options [C++] |
-Zc compiler options [C++] |
Conformance compiler options |
Zc compiler options [C++] |
|
| ms.assetid |
db1cc175-6e93-4a2e-9396-c3725d2d8f71 |
| caps.latest.revision |
15 |
| author |
corob-msft |
| ms.author |
corob |
| manager |
ghogen |
| translation.priority.ht |
cs-cz |
de-de |
es-es |
fr-fr |
it-it |
ja-jp |
ko-kr |
pl-pl |
pt-br |
ru-ru |
tr-tr |
zh-cn |
zh-tw |
|
You can use the /Zc compiler options to specify standard or Microsoft-specific compiler behavior.
/Zc:option{,option}
Remarks
When Visual Studio has implemented an extension to C or C++ that is not compatible with the standard, you can use a /Zc conformance option to specify standard-conforming or Microsoft-specific behavior. For some options, the Microsoft-specific behavior is the default, to prevent large-scale breaking changes to existing code. In other cases, the default is the standard behavior, where improvements in security, performance, or compatibility outweigh the costs of breaking changes. The default setting of each conformance option may change in newer versions of Visual Studio. For more information about each conformance option, see the topic for the specific option.
These are the /Zc compiler options:
| Option |
Behavior |
| auto[-] |
Enforce the new Standard C++ meaning for auto (on by default). |
| forScope[-] |
Enforce Standard C++ for scoping rules (on by default). |
| implicitNoexcept[-] |
Enable implicit noexcept on required functions (on by default). |
| inline[-] |
Remove unreferenced function or data if it is COMDAT or has internal linkage only (off by default). |
| referenceBinding[-] |
A UDT temporary will not bind to an non-const lvalue reference (off by default). |
| rvalueCast[-] |
Enforce Standard C++ explicit type conversion rules (on by default). |
| sizedDealloc[-] |
Enable C++14 global sized deallocation functions (on by default). |
| strictStrings[-] |
Disable string-literal to char* or wchar_t* conversion (off by default). |
| threadSafeInit[-] |
Enable thread-safe local static initialization (on by default). |
| throwingNew[-] |
Assume operator new throws on failure (off by default). |
| trigraphs[-] |
Enable trigraphs (obsolete, off by default). |
| wchar_t[-] |
wchar_t is a native type, not a typedef (on by default). |
For more information about conformance issues in Visual C++, see Nonstandard Behavior.
Compiler Options
Setting Compiler Options