mirror of
https://github.com/isocpp/CppCoreGuidelines.git
synced 2024-03-22 13:30:58 +08:00
Merge pull request #1202 from gumb0/patch-1
Remove unnecessary comments from C.42 examples
This commit is contained in:
commit
46ecdd6830
|
@ -5066,7 +5066,7 @@ Leaving behind an invalid object is asking for trouble.
|
||||||
##### Example
|
##### Example
|
||||||
|
|
||||||
class X2 {
|
class X2 {
|
||||||
FILE* f; // call init() before any other function
|
FILE* f;
|
||||||
// ...
|
// ...
|
||||||
public:
|
public:
|
||||||
X2(const string& name)
|
X2(const string& name)
|
||||||
|
@ -5090,7 +5090,7 @@ Leaving behind an invalid object is asking for trouble.
|
||||||
##### Example, bad
|
##### Example, bad
|
||||||
|
|
||||||
class X3 { // bad: the constructor leaves a non-valid object behind
|
class X3 { // bad: the constructor leaves a non-valid object behind
|
||||||
FILE* f; // call init() before any other function
|
FILE* f; // call is_valid() before any other function
|
||||||
bool valid;
|
bool valid;
|
||||||
// ...
|
// ...
|
||||||
public:
|
public:
|
||||||
|
|
Loading…
Reference in New Issue
Block a user