File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -16181,7 +16181,7 @@ Note that a C-style `(T)expression` cast means to perform the first of the follo
16181
16181
##### Example, bad
16182
16182
16183
16183
std::string s = "hello world";
16184
- double* p = (double*)(&s); // BAD
16184
+ double* p0 = (double*)(&s); // BAD
16185
16185
16186
16186
class base { public: virtual ~base() = 0; };
16187
16187
@@ -16194,7 +16194,7 @@ Note that a C-style `(T)expression` cast means to perform the first of the follo
16194
16194
};
16195
16195
16196
16196
derived1 d1;
16197
- base* p = &d1; // ok, implicit conversion to pointer to base is fine
16197
+ base* p1 = &d1; // ok, implicit conversion to pointer to base is fine
16198
16198
16199
16199
// BAD, tries to treat d1 as a derived2, which it is not
16200
16200
derived2* p2 = (derived2*)(p);
You can’t perform that action at this time.
0 commit comments