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/code-quality/using-the-cpp-core-guidelines-checkers.md
+4-8Lines changed: 4 additions & 8 deletions
Original file line number
Diff line number
Diff line change
@@ -1,7 +1,7 @@
1
1
---
2
2
title: Using the C++ Core Guidelines checkers
3
3
description: "How to set up and use the Microsoft C++ Code Analysis rules for C++ Core Guidelines."
4
-
ms.date: 12/16/2020
4
+
ms.date: 06/21/2023
5
5
ms.topic: "conceptual"
6
6
dev_langs:
7
7
- CPP
@@ -231,9 +231,9 @@ You can use the command-line option to temporarily disable all code analysis for
231
231
232
232
Sometimes it's useful to do focused code analysis and still use the Visual Studio IDE. Try the following sample scenario for large projects. It can save build time and make it easier to filter results:
233
233
234
-
1. In the command shell, set the `esp.extension`and `esp.annotationbuildlevel`environment variables.
234
+
1. In the command shell, set the `esp.extension` environment variable.
235
235
236
-
1. To inherit these variables, open Visual Studio from the command shell.
236
+
1. To inherit this variable, open Visual Studio from the command shell.
237
237
238
238
1. Load your project and open its properties.
239
239
@@ -269,10 +269,6 @@ You can run the C++ Core Checker only on specified files. Use the same approach
269
269
270
270
```xml
271
271
<ItemGroup>
272
-
<BuildMacroInclude="Esp_AnnotationBuildLevel">
273
-
<EnvironmentVariable>true</EnvironmentVariable>
274
-
<Value>Ignore</Value>
275
-
</BuildMacro>
276
272
<BuildMacroInclude="Esp_Extensions">
277
273
<EnvironmentVariable>true</EnvironmentVariable>
278
274
<Value>CppCoreCheck.dll</Value>
@@ -294,7 +290,7 @@ Code Analysis requires a few environment variables and compiler command-line opt
294
290
295
291
-**Environment variables**
296
292
-`set esp.extensions=cppcorecheck.dll` This tells the engine to load the C++ Core Guidelines module.
297
-
-`set esp.annotationbuildlevel=ignore` This disables the logic that processes SAL annotations. Annotations don't affect code analysis in the C++ Core Guidelines Checker, yet their processing takes time (sometimes a long time). This setting is optional, but highly recommended.
293
+
-Since Visual Studio 2019 we no longer recommend setting the `esp.annotationbuildlevel` environment variable because setting it can result in false positives. If seeing unexpected results, remove this variable from your environment.
298
294
-`set caexcludepath=%include%` We highly recommend that you disable warnings that fire on standard headers. You can add more paths here, for example the path to the common headers in your project.
0 commit comments