From cc747323ee1d86d20a1dbe0288183aa6dadfcf85 Mon Sep 17 00:00:00 2001 From: Markus Trippelsdorf Date: Wed, 23 Sep 2015 11:06:03 +0200 Subject: [PATCH] Fix syntax error in Rc-in-class-initializer --- CppCoreGuidelines.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CppCoreGuidelines.md b/CppCoreGuidelines.md index 9794ac8..fba6608 100644 --- a/CppCoreGuidelines.md +++ b/CppCoreGuidelines.md @@ -3741,7 +3741,7 @@ Setting a `Vector1` to empty after detecting an error is trivial. int j; public: X() :i{666}, s{"qqq"} { } // j is uninitialized - X(int i) :i{ii} {} // s is "" and j is uninitialized + X(int ii) :i{ii} {} // s is "" and j is uninitialized // ... }; @@ -3755,7 +3755,7 @@ How would a maintainer know whether `j` was deliberately uninitialized (probably int j {0}; public: X2() = default; // all members are initialized to their defaults - X2(int i) :i{ii} {} // s and j initialized to their defaults + X2(int ii) :i{ii} {} // s and j initialized to their defaults // ... };