Is it necessary to initialize member variables with nullptr or Q_NULLPTR in header files? If yes, why is it so required, when I do proper initialize it the ctor initialization list.
in MyDialog.h,
QDialog* m_Dialog = Q_NULLPTR;
and in MyDialog.cpp...I do
MDialog()::MDialog()
: QDialog()
, m_Dialog(new QDialog())
{
}
And in destructor, I do proper delete n setting it to nullptr.
Why is the below required?
QDialog* m_Dialog = Q_NULLPTR;