2 years ago
#70125
moayad karimeh
seteer und Getter conflict with default constructor
i write a c++ Code contain two clases and one derived class from both simultaneouously in main funktion i have an object from the derived class declared with no constructor because i have already declared a default constructor in the base classes and those will be inhereted in the derived class without problem, then a tried to modify the member variable through setter functions that i have declared in the base clases this also should from my point of wiew implemented without problem. the problem is when i try to execute the Programm it will be excuted as i dont declare setter functions the default constructor hier has the priority and will be excute again what should i do i want modify the memeber variables through setter
constructor
setter
0 Answers
Your Answer