From b01f4992850d896bc34e808d1a1ec7cf92aa3173 Mon Sep 17 00:00:00 2001 From: Pascal Cadotte Michaud Date: Fri, 18 Sep 2015 20:31:30 -0400 Subject: [PATCH 1/2] Fix two typos in the precondition section --- CppCoreGuidelines.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CppCoreGuidelines.md b/CppCoreGuidelines.md index 4c5d4bd..216ec7b 100644 --- a/CppCoreGuidelines.md +++ b/CppCoreGuidelines.md @@ -1076,8 +1076,8 @@ Ideally, that `Expects(x>=0)` should be part of the interface of `sqrt()` but th `// the sequence [p:q) is ordered using <` **Note**: Most member functions have as a precondition that some class invariant holds. -That invariant is established by a constructor and must be reestablished upon exit by evenry member function called from outside the class. -We don't need to mentioning it for each member function. +That invariant is established by a constructor and must be reestablished upon exit by every member function called from outside the class. +We don't need to mention it for each member function. **Enforcement**: (Not enforceable) From 95e8e527fb9c77aab6644344120b9324b7d8be31 Mon Sep 17 00:00:00 2001 From: Pascal Cadotte Michaud Date: Fri, 18 Sep 2015 20:39:15 -0400 Subject: [PATCH 2/2] typo: identfied -> identified --- CppCoreGuidelines.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CppCoreGuidelines.md b/CppCoreGuidelines.md index 216ec7b..7460e22 100644 --- a/CppCoreGuidelines.md +++ b/CppCoreGuidelines.md @@ -1104,7 +1104,7 @@ We don't need to mention it for each member function. **Note**: `Expects()` can also be used to check a condition in the middle of an algorithm. -**Enforcement**: (Not enforceable) Finding the variety of ways preconditions can be asserted is not feasible. Warning about those that can be easily identfied (assert()) has questionable value in the absence of a language facility. +**Enforcement**: (Not enforceable) Finding the variety of ways preconditions can be asserted is not feasible. Warning about those that can be easily identified (assert()) has questionable value in the absence of a language facility.