In what situations do you have to use initialization list rather than assignment in constructors.
Page 1 of 1
In what situations do you have to use initialization list rather than assignment in constructors.
When you want to use non-static const data members and reference data members you should use initialization list to initialize them.
Similar topics
» Difference between a copy constructor and an assignment operator.
» Difference between a copy constructor and an assignment operator.
» What is virtual constructors/destructors?
» When do you call copy constructors?
» What are the restrictions apply to constructors and destructors?
» Difference between a copy constructor and an assignment operator.
» What is virtual constructors/destructors?
» When do you call copy constructors?
» What are the restrictions apply to constructors and destructors?
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum
|
|