member-initialization
Initialization of member: bug in GCC or my thinking?
I\'ve got an enum type defined in the private section of my class. I have a member of this type defined as well. When I try to initialize this member in the constructor body, I get memory corruption p[详细]
2023-01-22 01:57 分类:问答How do C++ class members get initialized if I don't do it explicitly?
Suppose I have a class with private memebers ptr, name, pname, rname, crname and age.What happens if I don\'t initialize them myself? Here is an example:[详细]
2023-01-04 17:33 分类:问答How to refrain from CS2512 correctly
Please help me with the following problem: I have the following classes: class ChemicalElement { private:[详细]
2022-12-17 04:02 分类:问答