How would I write a C++ class of which only one can be created ever be instantiated in any program.
I know that
ClassName* objectName = new ClassName();
instantiates an object, but how would I make it so when you try to instantiate it more than once you still end up with a reference to the first instance?
Even if you could point me to a reference where I can read how this might be done I would greatly appreciate it.