diff --git a/CppCoreGuidelines.md b/CppCoreGuidelines.md index 1f5ea8f..e55bf44 100644 --- a/CppCoreGuidelines.md +++ b/CppCoreGuidelines.md @@ -808,8 +808,8 @@ Prefer [RAII](#Rr-raii): if (p==nullptr) throw Nullptr_error{}; int n = strlen(p); auto buf = new char[n]; - for (int i = 0; i> value; // check for errors - } + }; auto print(auto& output, const auto& value) { @@ -1736,7 +1736,7 @@ Small simple functions are easily inlined where the cost of a function call is s constexpr int max_exp = 17; // constexpr enables this to be used in Expects Expects(0<=n && n r, const X& v) // find v in r + X* find(array_view r, const X& v); // find v in r vector vec; // ...