diff --git a/CppCoreGuidelines.md b/CppCoreGuidelines.md index bc49873..28cb53a 100644 --- a/CppCoreGuidelines.md +++ b/CppCoreGuidelines.md @@ -17351,8 +17351,8 @@ Type safety profile summary: * [Type.2: Don't use `static_cast` downcasts. Use `dynamic_cast` instead](#Pro-type-downcast) * [Type.3: Don't use `const_cast` to cast away `const` (i.e., at all)](#Pro-type-constcast) * [Type.4: Don't use C-style `(T)expression` casts that would perform a `static_cast` downcast, `const_cast`, or `reinterpret_cast`](#Pro-type-cstylecast) +* [Type.4.1: Don't use `T(expression)` for casting](#Pro-fct-style-cast) * [Type.5: Don't use a variable before it has been initialized](#Pro-type-init) -* [Type.5.1: Don't use `T(expression)` for casting](#Pro-fct-style-cast) * [Type.6: Always initialize a member variable](#Pro-type-memberinit) * [Type.7: Avoid accessing members of raw unions. Prefer `variant` instead](#Pro-fct-style-cast) * [Type.8: Avoid reading from varargs or passing vararg arguments. Prefer variadic template parameters instead](#Pro-type-varargs) @@ -17548,7 +17548,7 @@ Note that a C-style `(T)expression` cast means to perform the first of the follo Issue a diagnostic for any use of a C-style `(T)expression` cast that would invoke a `static_cast` downcast, `const_cast`, or `reinterpret_cast`. To fix: Use a `dynamic_cast`, `const`-correct declaration, or `variant`, respectively. -### Type.5.1: Don't use `T(expression)` for casting. +### Type.4.1: Don't use `T(expression)` for casting. ##### Reason