From 1c53b29a3af4c15fe82adf1014ec32c1ab564ef4 Mon Sep 17 00:00:00 2001 From: Shalom Craimer Date: Thu, 4 May 2017 11:19:31 +0300 Subject: [PATCH] C.148 - Fixing Travis-reported errors discovered so far in the code example --- CppCoreGuidelines.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/CppCoreGuidelines.md b/CppCoreGuidelines.md index 3e7df8c..a3daabf 100644 --- a/CppCoreGuidelines.md +++ b/CppCoreGuidelines.md @@ -7325,21 +7325,21 @@ The example below describes a `ShapeOwner` that takes ownership of constructed ` std::vector view_of_evens; std::vector view_of_trisyms; - void add( Shape * const item ) + void add(Shape * const item) { // Ownership is always taken - owned.emplace_back( item ); + owned.emplace_back(item); // Check the GeometricAttributes and add the shape to none/one/some/all of the views - if( auto even = dynamic_cast( item ) ) + if (auto even = dynamic_cast(item)) { - view_of_evens.emplace_back( even ); + view_of_evens.emplace_back(even); } - if( auto trisym = dynamic_cast( item ) ) + if (auto trisym = dynamic_cast(item)) { - view_of_trisyms.emplace_back( trisym ); + view_of_trisyms.emplace_back(trisym); } } };