Singletons and global state

programming — Tags: , , , , — Glen @ 8:32 am

A very useful article from Google’s Miško Hevery about the problems with the Singleton design pattern. Essentially, Singleton’s rely on a global instance variable which could point to any number of other variables, thus creating a global state. This causes problems when you want to test your code.

  • Share/Save/Bookmark

0 Comments »

No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a comment

This work is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 3.0 Unported License.
(c) 2009 Glen Scott - Keeping it simple | powered by WordPress with Barecity