Skip to content

Commit c303f59

Browse files
committed
Merging changes synced from https://github.com/MicrosoftDocs/cpp-docs-pr (branch live)
2 parents 1d1510d + d04dfe9 commit c303f59

File tree

3 files changed

+20
-7
lines changed

3 files changed

+20
-7
lines changed

docs/build/reference/sdl-enable-additional-security-checks.md

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: "/sdl (Enable Additional Security Checks)"
3-
ms.date: "11/04/2016"
3+
ms.date: "11/26/2018"
44
f1_keywords: ["VC.Project.VCCLCompilerTool.SDLCheck"]
55
ms.assetid: 3dcf86a0-3169-4240-9f29-e04a9f535826
66
---
@@ -42,7 +42,17 @@ When **/sdl** is enabled, the compiler generates code to perform these checks at
4242

4343
- Performs limited pointer sanitization. In expressions that do not involve dereferences and in types that have no user-defined destructor, pointer references are set to a non-valid address after a call to `delete`. This helps to prevent the reuse of stale pointer references.
4444

45-
- Performs class member initialization. Automatically initializes all class members to zero on object instantiation (before the constructor runs). This helps prevent the use of uninitialized data associated with class members that the constructor does not explicitly initialize.
45+
- Performs class member pointer initialization. Automatically initializes class members of pointer type to **nullptr** on object instantiation (before the constructor runs). This helps prevent the use of uninitialized pointers that the constructor does not explicitly initialize. The compiler-generated member pointer initialization is called as long as:
46+
47+
- The object is not allocated using a custom (user defined) `operator new`
48+
49+
- The object is not allocated as part of an array (for example `new A[x]`)
50+
51+
- The class is not managed or imported
52+
53+
- The class has a user-defined default constructor.
54+
55+
To be initialized by the compiler-generated class initialization function, a member must be a pointer, and not a property or constant.
4656

4757
## Remarks
4858

docs/build/reference/std-specify-language-standard-version.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,11 @@ Enable supported C++ language features from the specified version of the C++ lan
1010

1111
## Syntax
1212

13-
> /std:[c++14|c++17|c++latest]
13+
> /std:\[c++14\|c++17\|c++latest]
1414
1515
## Remarks
1616

17-
The **/std** option is available in Visual Studio 2017 and later. It is used to control the version-specific ISO C++ programming language standard features enabled during compilation of your code. This option allows you to disable support for certain new language and library features that may break your existing code that conforms to a particular version of the language standard. By default, **/std:c++14** is specified, which disables language and standard library features found in later versions of the C++ language standard. Use **/std:c++17** to enable C++17 standard-specific features and behavior. To explicitly enable the latest supported compiler and standard library features, use **/std:c++latest**.
17+
The **/std** option is available in Visual Studio 2017 and later. It is used to control the version-specific ISO C++ programming language standard features enabled during compilation of your code. This option allows you to disable support for certain new language and library features that may break your existing code that conforms to a particular version of the language standard. By default, **/std:c++14** is specified, which disables language and standard library features found in later versions of the C++ language standard. Use **/std:c++17** to enable C++17 standard-specific features and behavior. To explicitly enable the currently implemented compiler and standard library features proposed for the next draft standard, use **/std:c++latest**.
1818

1919
The default **/std:c++14** option enables the set of C++14 features implemented by the Visual C++ compiler. This option disables compiler and standard library support for features that are changed or new in more recent versions of the language standard, with the exception of some C++17 features already implemented in previous releases of the Visual C++ compiler. To avoid breaking changes for users who have already taken dependencies on the features available as of Visual Studio 2015 Update 2, these features remain enabled when the **/std:c++14** option is specified:
2020

@@ -32,7 +32,10 @@ For additional information on which C++14 and C++17 features are enabled when **
3232

3333
The **/std:c++17** option enables the full set of C++17 features implemented by the Visual C++ compiler. This option disables compiler and standard library support for features that are changed or new in versions of the Working Draft and defect updates of the C++ Standard after C++17.
3434

35-
The **/std:c++latest** option enables the set of C++ language and library features implemented by Visual C++ to track the most recent C++20 Working Draft and defect updates of the C++ Standard that are not included in C++17. Use this switch to get the post-C++17 language features supported by the compiler and standard library. For a list of supported language and library features, see [What's New for Visual C++](../../what-s-new-for-visual-cpp-in-visual-studio.md). The **/std:c++latest** option does not enable features guarded by the **/experimental** switch.
35+
The **/std:c++latest** option enables the post-C++17 language and library features currently implemented in the compiler and libraries. These may include features from the C++20 Working Draft and defect updates of the C++ Standard that are not included in C++17, as well as experimental proposals for the draft standard. For a list of supported language and library features, see [What's New for Visual C++](../../what-s-new-for-visual-cpp-in-visual-studio.md). The **/std:c++latest** option does not enable features guarded by the **/experimental** switch, but may be required to enable them.
36+
37+
> [!IMPORTANT]
38+
> The compiler and library features enabled by **/std:c++latest** are provided as-is and without support. They are subject to breaking changes or removal without notice. They are intended as a preview of language features that may appear in the next version of the standard, but the standard is a work in progress. Use **/std:c++17** to use the features in the latest ISO C++ standard.
3639
3740
The **/std** option in effect during a C++ compilation can be detected by use of the [\_MSVC\_LANG](../../preprocessor/predefined-macros.md) preprocessor macro. For more information, see [Preprocessor Macros](../../preprocessor/predefined-macros.md).
3841

docs/dotnet/using-verifiable-assemblies-with-sql-server-cpp-cli.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: "Using Verifiable Assemblies with SQL Server (C++/CLI)"
3-
ms.date: "10/17/2019"
3+
ms.date: "10/17/2018"
44
helpviewer_keywords: ["verifiable assemblies [C++], with SQL Server"]
55
ms.assetid: 5248a60d-aa88-4ff3-b30a-b791c3ea2de9
66
---
@@ -71,4 +71,4 @@ sqlcmd -S MyServer -E -i myScript.sql -o myResult.txt
7171

7272
## See Also
7373

74-
[Classes and Structs](../cpp/classes-and-structs-cpp.md)
74+
[Classes and Structs](../cpp/classes-and-structs-cpp.md)

0 commit comments

Comments
 (0)