You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CppCoreGuidelines.md
+4-4Lines changed: 4 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -7012,7 +7012,7 @@ Here, we ignore such cases.
7012
7012
* [R.30: Take smart pointers as parameters only to explicitly express lifetime semantics](#Rr-smartptrparam)
7013
7013
* [R.31: If you have non-`std` smart pointers, follow the basic pattern from `std`](#Rr-smart)
7014
7014
* [R.32: Take a `unique_ptr<widget>` parameter to express that a function assumes ownership of a `widget`](#Rr-uniqueptrparam)
7015
-
* [R.33: Take a `unique_ptr<widget>&` parameter to express that a function reseats the`widget`](#Rr-reseat)
7015
+
* [R.33: Take a `unique_ptr<widget>&` parameter to express that a function reseats the`widget`](#Rr-reseat)
7016
7016
* [R.34: Take a `shared_ptr<widget>` parameter to express that a function is part owner](#Rr-sharedptrparam-owner)
7017
7017
* [R.35: Take a `shared_ptr<widget>&` parameter to express that a function might reseat the shared pointer](#Rr-sharedptrparam)
7018
7018
* [R.36: Take a `const shared_ptr<widget>&` parameter to express that it might retain a reference count to the object ???](#Rr-sharedptrparam-const)
@@ -8430,7 +8430,7 @@ solution:
8430
8430
j = f4();
8431
8431
}
8432
8432
8433
-
Now the compiler cannot even simply detect a used-before-set. Further, we've introduced complexity in the state space for widget: which operations are valid on an `unint` widget and which are not?
8433
+
Now the compiler cannot even simply detect a used-before-set. Further, we've introduced complexity in the state space for widget: which operations are valid on an `uninit` widget and which are not?
8434
8434
8435
8435
##### Note
8436
8436
@@ -9112,7 +9112,7 @@ It is easy to overlook the fallthrough. Be explicit:
9112
9112
break;
9113
9113
case Warning:
9114
9114
write_event_log();
9115
-
// fall through
9115
+
// fallthrough
9116
9116
case Error:
9117
9117
display_error_window(); // Bad
9118
9118
break;
@@ -9134,7 +9134,7 @@ Multiple case labels of a single statement is OK:
0 commit comments