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/c26462.md
+20-1Lines changed: 20 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,7 +4,26 @@ ms.date: 03/22/2018
4
4
ms.topic: reference
5
5
f1_keywords: ["C26462"]
6
6
helpviewer_keywords: ["C26462"]
7
+
description: CppCoreCheck rule that enforces C++ Core Guidelines Con.4
7
8
---
8
9
# C26462 USE_CONST_POINTER_FOR_VARIABLE
9
10
10
-
The value pointed to by '%variable%' is assigned only once, mark it as a pointer to `const`. See [C++ Core Guidelines con.4](https://github.com/isocpp/CppCoreGuidelines/blob/master/CppCoreGuidelines.md#con4-use-const-to-define-objects-with-values-that-do-not-change-after-construction).
11
+
The value pointed to by '%variable%' is assigned only once, mark it as a pointer to `const` (con.4).
12
+
13
+
Pointers to variables whose values remain unchanged should be marked as const.
0 commit comments