From: Dave Gomboc (dave_at_[hidden])
Date: 2001-11-13 22:02:20
> > I am also looking in this direction for some time now. Here what I
> > think we need to make a really reusable singleton. The singleton
> > design should be able to adopt following design desision made by
> Have you looked at Andrei Alexandrescu's work? It's possible that
> the reusable singleton class you're looking for already exists.
There's an article in More C++ Gems (Robert C. Martin, Ed.) by Steve
Ball and John Crawford titled "Monostate classes: the power of one".
Apparently the article originally appeared in the May 1997 C++ Report
(Vol. 9(5)). I was impressed by it and (perhaps naively? :-) came to
the conclusion that the Monostate pattern was generally superior to the
Singleton pattern. If that's actually true, then perhaps it's not a
good idea to provide an implementation of the Singleton pattern?
It's been a while since I read the article -- it could be that I've
failed to remember some limitation of Monostate that doesn't hamper a
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk