Skip to content

Commit ef045db

Browse files
committed
feedback
1 parent 65f3f97 commit ef045db

File tree

1 file changed

+14
-14
lines changed

1 file changed

+14
-14
lines changed

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

+14-14
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ The Microsoft C++ compiler in Visual Studio 2017 and later versions doesn't supp
2727

2828
## C++ standards support
2929

30-
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).
30+
Detect whether the **`/std`** option is in effect during a C++ compilation with the [`_MSVC_LANG`](../../preprocessor/predefined-macros.md) preprocessor macro. For more information, see [Preprocessor Macros](../../preprocessor/predefined-macros.md).
3131

3232
> [!IMPORTANT]
3333
> Because some existing code depends on the value of the macro `__cplusplus` being `199711L`, the MSVC compiler doesn't change the value of this macro unless you explicitly opt in by setting [`/Zc:__cplusplus`](zc-cplusplus.md). Specify `/Zc:__cplusplus` and the **`/std`** option to set `__cplusplus` to the appropriate value.
@@ -38,7 +38,7 @@ Enables C++14 standard-specific features implemented by the MSVC compiler. This
3838

3939
This option disables compiler and standard library support for features that are changed or new in more recent versions of the language standard. However, it doesn't disable some C++17 features already implemented in previous releases of the MSVC compiler. For more information, see [Microsoft C/C++ language conformance](../../overview/visual-cpp-language-conformance.md). The tables indicate which C++17 features are enabled when you specify **`/std:c++14`**.
4040

41-
The following features remain enabled when the **`/std:c++14`** option is specified to avoid breaking changes for users who have already taken dependencies on the features available in or before Visual Studio 2015 Update 2:
41+
The following features remain enabled when the **`/std:c++14`** option is specified to avoid breaking changes for users who took dependencies on features available in or before Visual Studio 2015 Update 2:
4242

4343
- [Rules for `auto` with braced-init-lists](https://wg21.link/n3922)
4444
- [`typename` in template template-parameters](https://wg21.link/n4051)
@@ -54,19 +54,19 @@ Depending on the MSVC compiler version or update level, C++17 features may not b
5454

5555
### `/std:c++20`
5656

57-
- Enables C++20 standard-specific features and behavior. Available starting in Visual Studio 2019 version 16.11, it enables the full set of C++20 features implemented by the MSVC compiler. Note that Visual Studio 2022 version 17.0 does not support `std::format`, the C++20 `<chrono>` formatting extensions, and the range factories and range adaptors from `<ranges>` under **`/std:c++20`** due to late-breaking changes in those features immediately after publication of the Standard.
58-
- Enables the standard conformance mode provided by [**`/permissive-`**](./permissive-standards-conformance.md) unless explicitly overriden with **`/permissive`**.
59-
- Disables compiler and standard library support for features that are new or changed after C++20. It specifically disables post-C++20 changes in the C++ Standard and versions of the Working Draft. It doesn't disable retroactive defect updates of the C++ Standard.
57+
Enables C++20 standard-specific features and behavior. Available starting in Visual Studio 2019 version 16.11, it enables the full set of C++20 features implemented by the MSVC compiler. Visual Studio 2022 version 17.0 doesn't support `std::format`, the C++20 `<chrono>` formatting extensions, and the range factories and range adaptors from `<ranges>` under **`/std:c++20`** due to late-breaking changes in those features immediately after publication of the Standard.
58+
59+
Enables the standard conformance mode provided by [**`/permissive-`**](./permissive-standards-conformance.md) unless explicitly overridden with **`/permissive`**.
60+
61+
Disables compiler and standard library support for features that are new or changed after C++20. It specifically disables post-C++20 changes in the C++ Standard and versions of the Working Draft. It doesn't disable retroactive defect updates of the C++ Standard.
6062

6163
### `/std:c++23preview`
6264

63-
- Enables preview C++23 standard-specific features and behavior. Available starting in Visual Studio 2022 version 17.13. Preview features may change and may not be ABI compatible across releases.
64-
- This switch will eventually be removed when the `/std:c++23` switch is implemented.
65+
Enables preview C++23 standard-specific features and behavior. Available starting in Visual Studio 2022 version 17.13. Preview features may change and may not be ABI compatible across releases.
66+
67+
This switch will be removed when the `/std:c++23` switch is implemented--at which point all of the C++23 features will be implemented and ABI stable.
6568

66-
This switch differs from `/std:c++latest` in the following ways:
67-
- Only features in the published [N4950 ISO C++23 final working draft](https://wg21.link/n4950) are enabled. No features in the latest [N5001 working draft (tenatively named C++26)](https://wg21.link/n5001) are enabled.
68-
- This switch will be removed in a release following the completion of the C++23 features.
69-
- ??? Note that Visual Studio 2022 version 17.0 does not support the C++23 `<chrono>` formatting extensions under **`/std:c++23preview`** due to late-breaking changes in those features immediately after publication of the Standard.
69+
This switch differs from `/std:c++latest` in that it only enables features that are part of the C++23 standard. It does not enable experimental or in-progress features.
7070

7171
### `/std:c++latest`
7272

@@ -76,22 +76,22 @@ Depending on the MSVC compiler version or update level, C++17, C++20, C++23, or
7676

7777
In versions of Visual Studio 2019 before version 16.11, **`/std:c++latest`** is required to enable all the compiler and standard library features of C++20.
7878

79-
Since Visual Studio 2019 version 16.8, the **`/std:c++latest`** option has enabled the standard conformance mode provided by [**`/permissive-`**](./permissive-standards-conformance.md) unless explicitly overriden with **`/permissive`**.
79+
Since Visual Studio 2019 version 16.8, the **`/std:c++latest`** option has enabled the standard conformance mode provided by [**`/permissive-`**](./permissive-standards-conformance.md) unless explicitly overridden with **`/permissive`**.
8080

8181
For a list of supported language and library features, see [What's New for C++ in Visual Studio](../../overview/what-s-new-for-visual-cpp-in-visual-studio.md).
8282

8383
The **`/std:c++latest`** option doesn't enable features guarded by the **`/experimental`** switch, but may be required to enable them.
8484

8585
> [!NOTE]
86-
> The compiler and library features enabled by **`/std:c++latest`** may appear in a future C++ standard. Features that have not been approved are subject to breaking changes or removal without notice and are provided on an as-is basis.
86+
> The compiler and library features enabled by **`/std:c++latest`** may appear in a future C++ standard. Features that haven't been approved are subject to breaking changes or removal without notice and are provided on an as-is basis.
8787
8888
## C standards support
8989

9090
You can invoke the Microsoft C compiler by using the [`/TC` or `/Tc`](tc-tp-tc-tp-specify-source-file-type.md) compiler option. It's used by default for code that has a *`.c`* file extension, unless overridden by a **`/TP`** or **`/Tp`** option. The default C compiler (that is, the compiler when **`/std:c11`** or **`/std:c17`** isn't specified) implements ANSI C89, but includes several Microsoft extensions, some of which are part of ISO C99. Some Microsoft extensions to C89 can be disabled by using the [`/Za`](za-ze-disable-language-extensions.md) compiler option, but others remain in effect. It isn't possible to specify strict C89 conformance. The compiler doesn't implement several required features of C99, so it isn't possible to specify C99 conformance, either.
9191

9292
### `/std:c11`
9393

94-
- Enables ISO C11 conformance. It's available starting in Visual Studio 2019 version 16.8.
94+
Enables ISO C11 conformance. It's available starting in Visual Studio 2019 version 16.8.
9595

9696
### `/std:c17`
9797

0 commit comments

Comments
 (0)