You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/overview/visual-cpp-language-conformance.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -516,9 +516,9 @@ These algorithms aren't presently parallelized:
516
516
517
517
<aname="note_14"></a> __14__ These C++17 and C++20 features are always enabled, even when [`/std:c++14`](../build/reference/std-specify-language-standard-version.md) (the default) is specified. The reason is either because the feature was implemented before the introduction of the **`/std`** options, or because conditional implementation was undesirably complex.
518
518
519
-
<aname="note_17"></a> __17__ These features are enabled by the [`/std:c++17`](../build/reference/std-specify-language-standard-version.md)(or [`/std:c++latest`](../build/reference/std-specify-language-standard-version.md)) compiler option.
519
+
<aname="note_17"></a> __17__ These features are enabled by the [`/std:c++17`](../build/reference/std-specify-language-standard-version.md) or later compiler option.
520
520
521
-
<aname="note_20"></a> __20__ In versions through Visual Studio 2019 version 16.10, these features are enabled by the [`/std:c++latest`](../build/reference/std-specify-language-standard-version.md) compiler option. When the C++20 implementation is complete, we'll add a new **`/std:c++20`** compiler option to enable these features.
521
+
<aname="note_20"></a> __20__ In versions through Visual Studio 2019 version 16.10, these features are enabled by the [`/std:c++latest`](../build/reference/std-specify-language-standard-version.md) compiler option. Visual Studio 2019 version 16.11 added the [`/std:c++20`](../build/reference/std-specify-language-standard-version.md) compiler option to enable these features.
522
522
523
523
<aname="note_DR"></a> __DR__ These features are enabled in all C++ [`/std`](../build/reference/std-specify-language-standard-version.md) compiler option modes. The C++ Standard committee adopted this change as a retroactive Defect Report to C++11 and all later versions.
Copy file name to clipboardExpand all lines: docs/overview/what-s-new-for-visual-cpp-in-visual-studio.md
+6-6Lines changed: 6 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -66,7 +66,7 @@ For a summary of new features and bug fixes in Visual Studio version 16.9, see [
66
66
67
67
For a summary of new features and bug fixes in Visual Studio version 16.8, see [What's New in Visual Studio 2019 version 16.8](/visualstudio/releases/2019/release-notes-v16.8).
68
68
69
-
- C++20 Coroutines are now supported under [`/std:c++latest`](../build/reference/std-specify-language-standard-version.md) and the \<coroutine> header.
69
+
- C++20 Coroutines are now supported under [`/std:c++latest`](../build/reference/std-specify-language-standard-version.md)(or **`/std:c++20`** starting in Visual Studio 2019 version 16.11) and the \<coroutine> header.
70
70
71
71
- IntelliSense now provides support for C++20 \<concepts> and \<ranges> headers, and rename and browsing for concept definitions.
72
72
@@ -178,7 +178,7 @@ For a summary of new features and bug fixes in Visual Studio version 16.4, see [
178
178
179
179
- Updates to MSVC's C++ Standard Library:
180
180
- C++17: Implemented `to_chars()` general precision, completing [P0067R5](https://wg21.link/P0067R5) Elementary String Conversions (charconv). This completes implementation of all library features in the C++17 Standard.
181
-
- C++20: Implemented [P1754R1](https://wg21.link/P1754R1) Rename concepts to standard_case. To include preview features from the latest C++ Working Draft, use the **`/std:c++latest`** compiler option. The option can also be set in the **Configuration Properties > C/C++ > Language** project property page using the **C++ Language Standard** property.
181
+
- C++20: Implemented [P1754R1](https://wg21.link/P1754R1) Rename concepts to standard_case. To include preview features from the latest C++ Working Draft, use the **`/std:c++latest`** compiler option (or **`/std:c++20`** starting in Visual Studio 2019 version 16.11). The option can also be set in the **Configuration Properties > C/C++ > Language** project property page using the **C++ Language Standard** property.
182
182
183
183
- A new collection of tools named [C++ Build Insights](../build-insights/get-started-with-cpp-build-insights.md) is now available. For more information about the announcement, see the [C++ Team Blog](https://devblogs.microsoft.com/cppblog/introducing-c-build-insights/).
184
184
@@ -190,7 +190,7 @@ For a summary of new features and bug fixes in Visual Studio version 16.3, see [
190
190
191
191
- IntelliSense member lists are now filtered based on type qualifiers, for example, `const std::vector` now filters out methods such as `push_back`.
192
192
193
-
- We added these C++20 Standard Library preview features (available under **`/std:c++latest`**):
193
+
- We added these C++20 Standard Library preview features (available under **`/std:c++latest`**, or **`/std:c++20`** starting in Visual Studio 2019 version 16.11):
@@ -248,7 +248,7 @@ For a summary of new features and bug fixes in Visual Studio version 16.1, see [
248
248
249
249
### C++ compiler
250
250
251
-
- These C++20 preview features have been implemented in the C++ compiler, available under **`/std:c++latest`**:
251
+
- These C++20 preview features have been implemented in the C++ compiler, available under **`/std:c++latest`** (or **`/std:c++20`** starting in Visual Studio 2019 version 16.11):
252
252
- Increased ability to find function templates via argument-dependent lookup for function call expressions with explicit template arguments ([P0846R0](http://wg21.link/p0846r0)).
253
253
- Designated initialization ([P0329R4](https://wg21.link/p0329r4)), which allows specific members to be selected in aggregate initialization, for example, by using the `Type t { .member = expr }` syntax.
Copy file name to clipboardExpand all lines: docs/porting/ide-tools-for-upgrading-code.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,11 +10,11 @@ Visual Studio helps you upgrade legacy C++ code with compiler options, code anal
10
10
11
11
- Code that was formerly allowed by the Microsoft C++ compiler (MSVC) but never conformed to the C++ standard.
12
12
13
-
To upgrade older non-conformant MSVC code, turn on the [/permissive-](../build/reference/permissive-standards-conformance.md) compiler option. All instances of non-conformant usages are underlined with red squiggles in the code editor. The error messages in the **Error List** window include a recommendation for how to fix the error. Click on the error code to go to its help page in the documentation. If fixing all the errors at once is impractical, you can upgrade non-conformant code in stages by turning on the **permissive-** option, fixing some errors, then turning the option off again. The code will compile with the new improvements, and you can go back and fix the remaining issues at a later time. See the [/permissive-](../build/reference/permissive-standards-conformance.md) page for examples of non-conformant MSVC code.
13
+
To upgrade older non-conforming MSVC code, turn on the [`/permissive-`](../build/reference/permissive-standards-conformance.md) compiler option. All instances of non-conforming usages are underlined with red squiggles in the code editor. The error messages in the **Error List** window include a recommendation for how to fix the error. Click on the error code to go to its help page in the documentation. If fixing all the errors at once is impractical, you can upgrade non-conforming code in stages by turning on the **`/permissive-`** option, fixing some errors, then turning the option off again. The code will compile with the new improvements, and you can go back and fix the remaining issues at a later time. See the [`/permissive-`](../build/reference/permissive-standards-conformance.md) page for examples of non-conforming MSVC code.
14
14
15
15
- Code that was permitted in an earlier version of the C++ standard but has been deprecated or removed in a later version.
16
16
17
-
To upgrade to a newer language standard, set the [C++ Language Standard](../build/reference/std-specify-language-standard-version.md) option to the desired standard and fix any compile errors that are raised. In general, we recommend setting the language standard to [/std:c++17](../build/reference/std-specify-language-standard-version.md). The errors raised when upgrading to a newer standard are not related to the errors raised when using the **permissive-** option.
17
+
To upgrade to a newer language standard, set the [C++ Language Standard](../build/reference/std-specify-language-standard-version.md) option to the desired standard and fix any compile errors that are raised. In general, we recommend setting the language standard to [`/std:c++17`](../build/reference/std-specify-language-standard-version.md) or [`/std:c++20`](../build/reference/std-specify-language-standard-version.md). The errors raised when upgrading to a newer standard are not related to the errors raised when using the **`/permissive-`** option.
18
18
19
19
- Code that conforms to all versions of the standard but is no longer considered best practice in modern C++.
Copy file name to clipboardExpand all lines: docs/preprocessor/predefined-macros.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -285,7 +285,7 @@ MSVC supports these additional predefined macros.
285
285
286
286
For more information, see [Visual C++ Compiler Version](https://devblogs.microsoft.com/cppblog/visual-c-compiler-version/) in the Microsoft C++ Team Blog.
287
287
288
-
-`_MSVC_LANG` Defined as an integer literal that specifies the C++ language standard targeted by the compiler. It's set only in code compiled as C++. The macro is the integer literal value 201402L by default, or when the [`/std:c++14`](../build/reference/std-specify-language-standard-version.md) compiler option is specified. The macro is set to 201703L if the [`/std:c++17`](../build/reference/std-specify-language-standard-version.md) compiler option is specified. It's set to a higher, unspecified value when the [`/std:c++latest`](../build/reference/std-specify-language-standard-version.md) option is specified. Otherwise, the macro is undefined. The `_MSVC_LANG` macro and [**`/std`** (Specify Language Standard Version)](../build/reference/std-specify-language-standard-version.md) compiler options are available beginning in Visual Studio 2015 Update 3.
288
+
-`_MSVC_LANG` Defined as an integer literal that specifies the C++ language standard targeted by the compiler. It's set only in code compiled as C++. The macro is the integer literal value `201402L` by default, or when the [`/std:c++14`](../build/reference/std-specify-language-standard-version.md) compiler option is specified. The macro is set to `201703L` if the [`/std:c++17`](../build/reference/std-specify-language-standard-version.md) compiler option is specified. The macro is set to `202002L` if the [`/std:c++20`](../build/reference/std-specify-language-standard-version.md) compiler option is specified. It's set to a higher, unspecified value when the [`/std:c++latest`](../build/reference/std-specify-language-standard-version.md) option is specified. Otherwise, the macro is undefined. The `_MSVC_LANG` macro and [`/std` (Specify language standard version)](../build/reference/std-specify-language-standard-version.md) compiler options are available beginning in Visual Studio 2015 Update 3.
289
289
290
290
-`__MSVC_RUNTIME_CHECKS` Defined as 1 when one of the [`/RTC`](../build/reference/rtc-run-time-error-checks.md) compiler options is set. Otherwise, undefined.
Copy file name to clipboardExpand all lines: docs/standard-library/basic-string-class.md
+5-5Lines changed: 5 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1575,7 +1575,7 @@ If you modify the contents of the string returned by the `const` overload of `da
1575
1575
1576
1576
Before C++11, `data` didn't guarantee the returned string was null-terminated. Since C++11, `data` and `c_str` both return a null-terminated string, and are effectively the same.
1577
1577
1578
-
The non-`const` overload is new in C++17. To use it, specify the **`/std:c++17`** or **`/std:c++latest`** compiler option.
1578
+
The non-`const` overload is new in C++17. To use it, specify the **`/std:c++17`** or later compiler option.
1579
1579
1580
1580
### Example
1581
1581
@@ -1820,14 +1820,14 @@ Null-terminated character string containing the suffix to look for.
1820
1820
1821
1821
### Remarks
1822
1822
1823
-
`ends_with()` is new in C++20. To use it, specify the [`/std:c++latest`](../build/reference/std-specify-language-standard-version.md) compiler option.
1823
+
`ends_with()` is new in C++20. To use it, specify the [`/std:c++20`](../build/reference/std-specify-language-standard-version.md) or later compiler option.
1824
1824
1825
1825
See [`starts_with`](#starts_with) to check if a string starts with the specified prefix.
1826
1826
1827
1827
### Example
1828
1828
1829
1829
```cpp
1830
-
// Requires /std:c++latest
1830
+
// Requires /std:c++20 or /std:c++latest
1831
1831
#include <string>
1832
1832
#include <iostream>
1833
1833
@@ -4641,14 +4641,14 @@ Null-terminated character string containing the prefix to look for.
4641
4641
4642
4642
### Remarks
4643
4643
4644
-
`starts_with()` is new in C++20. To use it, specify the [`/std:c++latest`](../build/reference/std-specify-language-standard-version.md) compiler option.
4644
+
`starts_with()` is new in C++20. To use it, specify the [`/std:c++20`](../build/reference/std-specify-language-standard-version.md) or later compiler option.
4645
4645
4646
4646
See [`ends_with`](#ends_with) to see if a string ends with the specified suffix.
Copy file name to clipboardExpand all lines: docs/standard-library/basic-string-view-class.md
+5-5Lines changed: 5 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -141,7 +141,7 @@ If a function is asked to generate a sequence longer than [max_size](#max_size)
141
141
142
142
## Requirements
143
143
144
-
[std:c++17](../build/reference/std-specify-language-standard-version.md) or later.
144
+
[`std:c++17`](../build/reference/std-specify-language-standard-version.md) or later.
145
145
146
146
**Header:**\<string_view>
147
147
@@ -606,14 +606,14 @@ Null-terminated character string containing the suffix to look for.
606
606
607
607
### Remarks
608
608
609
-
`ends_with()` is new in C++20. To use it, specify the [/std:c++latest](../build/reference/std-specify-language-standard-version.md) compiler option.
609
+
`ends_with()` is new in C++20. To use it, specify the [`/std:c++20`](../build/reference/std-specify-language-standard-version.md) or later compiler option.
610
610
611
611
See [starts_with](#starts_with) to check if a string view starts with the specified prefix.
612
612
613
613
### Example
614
614
615
615
```cpp
616
-
// Requires /std:c++latest
616
+
// Requires /std:c++20 or /std:c++latest
617
617
#include <string>
618
618
#include <iostream>
619
619
@@ -1016,14 +1016,14 @@ Null-terminated character string containing the prefix to look for.
1016
1016
1017
1017
### Remarks
1018
1018
1019
-
`starts_with()` is new in C++20. To use it, specify the [/std:c++latest](../build/reference/std-specify-language-standard-version.md) compiler option.
1019
+
`starts_with()` is new in C++20. To use it, specify the [/std:c++20](../build/reference/std-specify-language-standard-version.md) or later compiler option.
1020
1020
1021
1021
See [ends_with](#ends_with) to see if a string ends with a suffix.
0 commit comments