Ahh I get it that makes sense thanks quzah, and thanks Cat for trying.
Ahh I get it that makes sense thanks quzah, and thanks Cat for trying.
Thor's self help tip:
Maybe a neighbor is tossing leaf clippings on your lawn, looking at your woman, or harboring desires regarding your longboat. You enslave his children, set his house on fire. He shall not bother you again.
OS: Windows XP
Compiler: MSVC
The moment of creation for an object is when the code that resulted from the declaration or new call gets executed. In both cases the code FIRST allocates memory and THEN calls the constructor, passing a pointer to that memory as this pointer. The memory holds random content at that time, but that gets changed in the constructor.Is it really that simple? If the constructor were a part of the object, how could it be used to construct that very object ?
In effect, constructors and destructors are there to help the "blackbox" aspect of a class, to make a class a self-contained entity.
All the buzzt!
CornedBee
"There is not now, nor has there ever been, nor will there ever be, any programming language in which it is the least bit difficult to write bad code."
- Flon's Law