|
|
|
|
@ -158,7 +158,7 @@ You can look at design concepts used to express the rules:
|
|
|
|
|
|
|
|
|
|
* assertion: ???
|
|
|
|
|
* error: ???
|
|
|
|
|
* exception: [exception guarantee[(???)]
|
|
|
|
|
* exception: exception guarantee (???)
|
|
|
|
|
* failure: ???
|
|
|
|
|
* invariant: ???
|
|
|
|
|
* leak: ???
|
|
|
|
|
@ -17428,6 +17428,7 @@ C++17
|
|
|
|
|
##### Enforcement
|
|
|
|
|
|
|
|
|
|
???
|
|
|
|
|
|
|
|
|
|
### <a name="Rstr-span"></a>Sl.str.11: Use `gsl::string_span` rather than `std::string_view` when you need to mutate a string
|
|
|
|
|
|
|
|
|
|
##### Reason
|
|
|
|
|
@ -17630,7 +17631,7 @@ This leads to longer programs and more errors caused by uninitialized and wrongl
|
|
|
|
|
i = g(x, c);
|
|
|
|
|
}
|
|
|
|
|
return i;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
The larger the distance between the uninitialized variable and its use, the larger the chance of a bug.
|
|
|
|
|
Fortunately, compilers catch many "used before set" errors.
|
|
|
|
|
|