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/build-insights/tutorials/build-insights-function-view.md
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -66,7 +66,7 @@ In the window for the ETL file, choose the **Functions** tab. It shows the funct
66
66
In the Function Name column, performPhysicsCalculations() is highlighted and marked with a fire icon.:::
67
67
:::image-end:::
68
68
69
-
The **Time [sec, %]** column shows how long it took to compile each function in [wall clock responsibility time (WCTR)](https://devblogs.microsoft.com/cppblog/faster-cpp-builds-simplified-a-new-metric-for-time/#:~:text=Today%2C%20we%E2%80%99d%20like%20to%20teach%20you%20about%20a,your%20build%2C%20even%20in%20the%20presence%20of%20parallelism). This metric distributes the wall clock time among functions based on their use of parallel compiler threads. For example, if two different threads are compiling two different functions simultaneously within a one-second period, each function’s WCTR is recorded as 0.5 seconds. This reflects each function’s proportional share of the total compilation time, taking into account the resources each consumed during parallel execution. Thus, WCTR provides a better measure of the impact each function has on the overall build time in environments where multiple compilation activities occur simultaneously.
69
+
The **Time [sec, %]** column shows how long it took to compile each function in [wall clock responsibility time (WCTR)](https://devblogs.microsoft.com/cppblog/faster-cpp-builds-simplified-a-new-metric-for-time/#:~:text=Today%2C%20we%E2%80%99d%20like%20to%20teach%20you%20about%20a,your%20build%2C%20even%20in%20the%20presence%20of%20parallelism). This metric distributes the wall clock time among functions based on their use of parallel compiler threads. For example, if two different threads are compiling two different functions simultaneously within a one-second period, each function's WCTR is recorded as 0.5 seconds. This reflects each function's proportional share of the total compilation time, taking into account the resources each consumed during parallel execution. Thus, WCTR provides a better measure of the impact each function has on the overall build time in environments where multiple compilation activities occur simultaneously.
70
70
71
71
The **Forceinline Size** column shows roughly how many instructions were generated for the function. Click the chevron before the function name to see the individual inlined functions that were expanded in that function how roughly how many instructions were generated for each.
Copy file name to clipboardExpand all lines: docs/build-insights/tutorials/build-insights-included-files-view.md
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -171,7 +171,7 @@ Or, you can right-click a file in the **Include Tree** view to jump to it in the
171
171
- The **Included Files** and **Include Tree** views provide a filter box to find a header file that you're interested in. It does partial matches on the name you provide.
172
172
- Sometimes the parse time reported for a header file is different depending on which file includes it. This can be due to the interplay of different `#define`s that affect which parts of the header are expanded, file caching, and other system factors.
173
173
- If you forget what the **Included Files** or **Include Tree** view is trying to show you, hover over the tab to see a tooltip that describes the view. For example, if you hover over the **Include Tree** tab, the tooltip says: "View that shows include statistics for every file where the children nodes are the files included by the parent node."
174
-
- You may see cases (like `Windows.h`) where the aggregated duration of all the times for a header file is longer than the duration of the entire build. What’s happening is that headers are being parsed on multiple threads at the same time. If two threads simultaneously spend one second parsing a header file, that's 2 seconds of build time even though only one second of wall clock time has gone by. For more information, see [wall clock responsibility time (WCTR)](https://devblogs.microsoft.com/cppblog/faster-cpp-builds-simplified-a-new-metric-for-time/#:~:text=Today%2C%20we%E2%80%99d%20like%20to%20teach%20you%20about%20a,your%20build%2C%20even%20in%20the%20presence%20of%20parallelism).
174
+
- You may see cases (like `Windows.h`) where the aggregated duration of all the times for a header file is longer than the duration of the entire build. What's happening is that headers are being parsed on multiple threads at the same time. If two threads simultaneously spend one second parsing a header file, that's 2 seconds of build time even though only one second of wall clock time has gone by. For more information, see [wall clock responsibility time (WCTR)](https://devblogs.microsoft.com/cppblog/faster-cpp-builds-simplified-a-new-metric-for-time/#:~:text=Today%2C%20we%E2%80%99d%20like%20to%20teach%20you%20about%20a,your%20build%2C%20even%20in%20the%20presence%20of%20parallelism).
This rule is enforced by checking if a lookup table has an initial size of 365 elements, but can be expanded to 366. However, it doesn't check if the table’s size is adjusted through proper leap year check or not, and so is a low confidence warning.
55
+
This rule is enforced by checking if a lookup table has an initial size of 365 elements, but can be expanded to 366. However, it doesn't check if the table's size is adjusted through proper leap year check or not, and so is a low confidence warning.
Copy file name to clipboardExpand all lines: docs/ide/include-cleanup-config.md
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -56,7 +56,7 @@ The `.editorconfig` settings that you can use with Include Cleanup are:
56
56
|--|--|--|--|
57
57
|`cpp_include_cleanup_add_missing_error_tag_type`</br></br>Sets the error level of add transitive include messages. |`none`</br>`suggestion`</br>`warning`</br>`error`|`cpp_include_cleanup_add_missing_error_tag_type = suggestion`|
58
58
|`cpp_include_cleanup_remove_unused_error_tag_type`</br></br>Sets the error level of remove unused include messages. |`none`</br>`suggestion`</br>`warning`</br>`error`</br>`dimmed`|`cpp_include_cleanup_remove_unused_error_tag_type = dimmed`|
59
-
|`cpp_include_cleanup_excluded_files`</br></br>Excludes the specified files from Include Cleanup messages. You won’t get a suggestion related to the header at all, whether to add it or that it's unused. |*filename*|`cpp_include_cleanup_excluded_files = vcruntime.h, vcruntime_string.h`|
59
+
|`cpp_include_cleanup_excluded_files`</br></br>Excludes the specified files from Include Cleanup messages. You won't get a suggestion related to the header at all, whether to add it or that it's unused. |*filename*|`cpp_include_cleanup_excluded_files = vcruntime.h, vcruntime_string.h`|
60
60
|`cpp_include_cleanup_required_files`</br></br>Specify that usage of *file1* requires *file2*. For example, specify that if you use `atlwin.h` that `altbase.h` must also be included. |*file1*:*file2*|`cpp_include_cleanup_required_files = atlwin.h:altbase.h, atlcom.h:altbase.h`|
61
61
|`cpp_include_cleanup_replacement_files`</br></br>Replaces *file1* with *file2* during Include Cleanup processing. For example, you may prefer using `cstdio` over `stdio.h`. If you have a file with both `#include <cstdio>` and `#include <stdio.h>` and you consume content only from `stdio.h`, with this setting Include Cleanup will tell you to remove `stdio.h` because it replaced the usage of `cstdio` with `stdio.h` during processing. If you don't use the contents from either, Include Cleanup will tell you to remove both.|*file1*:*file2*|`cpp_include_cleanup_replacement_files = stdio.h:cstdio,stdint.h:cstdint`|
62
62
|`cpp_include_cleanup_alternate_files`</br></br>Don't generate a message for indirect include *file2* if *file1* is included. For example, if you `#include <windows.h>` and are only using something from its indirectly included header `winerror.h`, Include Cleanup won't prompt to add `winerror.h`. Useful when you prefer to include a facade header file instead of the indirect includes it contains. |*file1*:*file2*|`cpp_include_cleanup_alternate_files = windows.h:winerror.h, windows.h:minwindef.h`|
Copy file name to clipboardExpand all lines: docs/ide/lnt-make-member-function-const.md
+7-7Lines changed: 7 additions & 7 deletions
Original file line number
Diff line number
Diff line change
@@ -8,7 +8,7 @@ monikerRange: ">=msvc-170"
8
8
---
9
9
# `lnt-make-member-function-const`
10
10
11
-
When a member function doesn’t modify the object's state, annotate it with the `const` keyword. This guidance comes from the [C++ Core Guideline Con.2](https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#con2-by-default-make-member-functions-const).
11
+
When a member function doesn't modify the object's state, annotate it with the `const` keyword. This guidance comes from the [C++ Core Guideline Con.2](https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#con2-by-default-make-member-functions-const).
12
12
13
13
## Example
14
14
@@ -19,16 +19,16 @@ class MyClass
19
19
{
20
20
public:
21
21
22
-
int getValue() { return value; } // Flagged: ‘getValue’ doesn't modify the object's state.
23
-
void setValue(int newValue) { value = newValue; } // OK: ‘setValue’ modifies the object's state.
22
+
int getValue() { return value; } // Flagged: 'getValue' doesn't modify the object's state.
23
+
void setValue(int newValue) { value = newValue; } // OK: 'setValue' modifies the object's state.
24
24
25
25
private:
26
26
27
27
int value = 42;
28
28
};
29
29
30
30
doublegetRadius()
31
-
{ // Flagged: ‘getRadius’ doesn't modify the object's state.
31
+
{ // Flagged: 'getRadius' doesn't modify the object's state.
32
32
return radius;
33
33
}
34
34
```
@@ -45,7 +45,7 @@ class MyClass
45
45
public:
46
46
47
47
int getValue() const { return value; } // Added const
48
-
void setValue(int newValue) { value = newValue; } // OK: ‘setValue’ modifies the object's state.
48
+
void setValue(int newValue) { value = newValue; } // OK: 'setValue' modifies the object's state.
49
49
50
50
private:
51
51
@@ -54,7 +54,7 @@ private:
54
54
};
55
55
56
56
doublegetRadius() const// added const
57
-
{ // ‘getRadius’ doesn't modify the object's state.
57
+
{ // 'getRadius' doesn't modify the object's state.
58
58
return radius;
59
59
}
60
60
```
@@ -75,4 +75,4 @@ The current implementation of this check allows you to add `const` to member fun
75
75
76
76
## See also
77
77
78
-
[IntelliSense code linter for C++ overview](cpp-linter-overview.md)
78
+
[IntelliSense code linter for C++ overview](cpp-linter-overview.md)
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
Original file line number
Diff line number
Diff line change
@@ -202,22 +202,22 @@ A partial list of new features:
202
202
203
203
- C++ structured diagnostics in the Output window and a new problem details window that provides more information about the error. For more information, see [Structured SARIF Output](../build/reference/sarif-output.md) and [Problem Details Window](/visualstudio/ide/reference/problem-details-window).
204
204
- A feature that lets you visualize the size and alignment of your classes, structs, unions, base types, or enums even before the code is compiled. Hover over the identifier and a Quick Info displays the size and alignment information.
205
-
- A feature that suggests when to mark member functions `const` because they don’t modify the object’s state. Hover over a member function and click the light bulb icon to mark the function as `const`.
205
+
- A feature that suggests when to mark member functions `const` because they don't modify the object's state. Hover over a member function and click the light bulb icon to mark the function as `const`.
206
206
- Visual Studio now prompts you to mark global functions as static via a screwdriver icon that appears by the function name. Click the screwdriver icon to mark the function as static.
207
207
- Unused #include directives are dimmed in the editor. You can hover over a dimmed include and use the light bulb menu to either remove that include or all unused includes. You can also add `#include` directives for entities that are indirectly included via other headers. For more information, see [Clean up C/C++ includes in Visual Studio](../ide/include-cleanup-overview.md).
208
208
- More Unreal Engine support:
209
209
- Unreal Engine Test Adapter lets you discover, run, manage, and debug your Unreal Engine tests without leaving the Visual Studio IDE.
210
210
- With Unreal Engine Code Snippets, you can find common Unreal Engine constructs as snippets in your member list.
211
211
- Build Insights is now integrated with Visual Studio 2022 and works with MSBuild and CMake projects using MSVC. You can now see additional information about the compilation of a function such as how long it took to compile and the number of ForceInlines, and the impact of header files on build time. For more information, see [Tutorial: Troubleshoot function inlining on build time](../build-insights/tutorials/build-insights-function-view.md) and [Tutorial: Troubleshoot header file impact on build time](../build-insights/tutorials/build-insights-included-files-view.md).
212
-
- Remote Linux unit test support now lets you run your CTest and GTest tests on your remote Linux machines from Visual Studio’s Test Explorer, just like your local tests.
212
+
- Remote Linux unit test support now lets you run your CTest and GTest tests on your remote Linux machines from Visual Studio's Test Explorer, just like your local tests.
213
213
214
214
## What's new for C++ in Visual Studio version 17.7
215
215
216
216
*Released Aug 2023*
217
217
218
218
| For more information about | See |
219
219
|---|---|
220
-
| What's new for C++ developers |[What’s new for C++ Developers in Visual Studio 2022 17.7](https://devblogs.microsoft.com/cppblog/whats-new-for-c-developers-in-visual-studio-2022-17-7/)|
220
+
| What's new for C++ developers |[What's new for C++ Developers in Visual Studio 2022 17.7](https://devblogs.microsoft.com/cppblog/whats-new-for-c-developers-in-visual-studio-2022-17-7/)|
221
221
| New C++ features specific to game development |[Unleashing the Power of Visual Studio 2022 for C++ Game Development](https://devblogs.microsoft.com/visualstudio/unleashing-the-power-of-visual-studio-2022-for-c-game-development/)|
222
222
| Standard Library (STL) merged C++23 features, LWG issue resolutions, performance improvements, enhanced behavior, and fixed bugs |[STL Changelog 17.7](https://github.com/microsoft/STL/wiki/VS-2022-Changelog#vs-2022-177)|
223
223
| New features in the Visual Studio 17.7 IDE |[Visual Studio 2022 version 17.7 Release Notes](/visualstudio/releases/2022/release-notes-v17.7)|
@@ -239,7 +239,7 @@ A partial list of new features:
239
239
240
240
| For more information about | See |
241
241
|---|---|
242
-
| What's new for C++ developers |[What’s New for C++ Developers in Visual Studio 2022 17.6](https://devblogs.microsoft.com/cppblog/visual-studio-17-6-for-cpp-devs/)|
242
+
| What's new for C++ developers |[What's New for C++ Developers in Visual Studio 2022 17.6](https://devblogs.microsoft.com/cppblog/visual-studio-17-6-for-cpp-devs/)|
243
243
| Standard Library (STL) merged C++23 features, LWG issue resolutions, performance improvements, enhanced behavior, and fixed bugs |[STL Changelog 17.6](https://github.com/microsoft/STL/wiki/VS-2022-Changelog#vs-2022-176)|
244
244
| New features in the Visual Studio 17.6 IDE |[Visual Studio 2022 version 17.6 Release Notes](/visualstudio/releases/2022/release-notes-v17.6)|
245
245
| C++ language conformance improvements in Visual Studio 2022 17.6 |[C++ Conformance improvements, behavior changes, and bug fixes in Visual Studio 2022](cpp-conformance-improvements.md#improvements_176)|
@@ -257,7 +257,7 @@ A partial list of new features includes:
257
257
258
258
| For more information about | See |
259
259
|---|---|
260
-
| What's new for C++ developers |[What’s New for C++ Developers in Visual Studio 2022 17.5](https://devblogs.microsoft.com/cppblog/visual-studio-17-5-for-cpp-devs/)|
260
+
| What's new for C++ developers |[What's New for C++ Developers in Visual Studio 2022 17.5](https://devblogs.microsoft.com/cppblog/visual-studio-17-5-for-cpp-devs/)|
261
261
| Standard Library (STL) merged C++23 features, LWG issue resolutions, performance improvements, enhanced behavior, and fixed bugs |[STL Changelog 17.5](https://github.com/microsoft/STL/wiki/VS-2022-Changelog#vs-2022-175)|
262
262
| New features in the Visual Studio 17.5 IDE |[Visual Studio 2022 version 17.5 Release Notes](/visualstudio/releases/2022/release-notes-v17.5)|
263
263
@@ -296,7 +296,7 @@ A partial list of new features includes:
296
296
297
297
| For more information about | See |
298
298
|---|---|
299
-
| What's new for C++ developers |[What’s New for C++ Developers in Visual Studio 2022 17.4](https://devblogs.microsoft.com/cppblog/whats-new-for-cpp-developers-in-visual-studio-2022-17-4/)|
299
+
| What's new for C++ developers |[What's New for C++ Developers in Visual Studio 2022 17.4](https://devblogs.microsoft.com/cppblog/whats-new-for-cpp-developers-in-visual-studio-2022-17-4/)|
300
300
| Standard Library (STL) merged C++23 features, LWG issue resolutions, performance improvements, enhanced behavior, and fixed bugs |[STL Changelog 17.4](https://github.com/microsoft/STL/wiki/VS-2022-Changelog#vs-2022-174)|
301
301
| New features in the Visual Studio 17.4 IDE |[Visual Studio 2022 version 17.4 Release Notes](/visualstudio/releases/2022/release-notes-v17.4)|
302
302
| C++ language conformance improvements in Visual Studio 2022 17.4 |[C++ Conformance improvements, behavior changes, and bug fixes in Visual Studio 2022](cpp-conformance-improvements.md#improvements_174)|
Copy file name to clipboardExpand all lines: docs/sanitizers/asan-continue-on-error.md
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -20,7 +20,7 @@ It's a good practice to create a checked build of your C or C++ app with ASAN tu
20
20
21
21
When your app finishes, you get a summary of the memory issues. With COE, you can compile and deploy an existing application into limited production to find memory safety issues. You can run the checked build for days to fully exercise the code, although the app will run slower due to the ASAN instrumentation.
22
22
23
-
You can use this feature to create a new shipping gate. If all your existing tests pass, but COE reports a memory safety error or a leak, don’t ship the new code or integrate it into a parent branch.
23
+
You can use this feature to create a new shipping gate. If all your existing tests pass, but COE reports a memory safety error or a leak, don't ship the new code or integrate it into a parent branch.
24
24
25
25
Don't deploy a build with COE enabled into production! COE is intended to be used in testing and development environments only. You shouldn't use an ASAN enabled build in production because of the performance impact of the instrumentation added to detect memory errors, the risk of exposing the internal implementation if errors are reported, and to avoid increasing the surface area of possible security exploits by shipping the library functions that ASAN substitutes for memory allocation, freeing, and so on.
0 commit comments