Download User's Guide

Transcript
Items Enforced
Effective C++ Items
Classes and
Functions:
Implementation
Inheritance and
Object-Oriented
58
29
Avoid returning
“handles” to internal data from const
member functions.
SV
Y
30
Avoid member
functions that
return pointers or
references to members less accessible than
themselves.
V
Y
31
Never return a reference to a local
object or a dereferenced pointer initialized by new
within the function.
PSV / SV
Y/Y
37
Never redefine an
inherited nonvirtual
function.
PV/V
Y/Y
38
Never redefine an
inherited default
parameter value.
I/V
N/Y
39
Avoid casts down
the inheritance
hierarchy.
I
N