rant dept.
So you know a bit of C++. So you've also read the first 10 pages of the Gang of Four book. So you think using C++ static members to limit instantiation of your classes is a neat idea. So every frigging class you implement is going to have that god-awful static getInstance(). And tomorrow your program needs multiple instances for your class. What do you do?
You kick yourself in the ass is what you do.
Singleton sucks. Please don't use it. Free your classes. Let them proliferate.
Real programmers can count their classes.
End Rant.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment