singleton pattern really necessary?
I was wondering, if a person wants there to be only one instance of a class, they can simply do something like:
class {
<class definition here>
} classInstance ;
which automatically creates a single instance of a class. Why go to the extent of locking the constructor, copy constructor, operator= etc? The only possible thing (that I can think of) that cannot be done is conveniently passing it as an argument to a function. Is there any other reason that would make a class-name necessary?
Shriramana Sharma.