Thread-safe singleton
-
I would like to hear your criticism about "this":http://developer.qt.nokia.com/wiki/Qt_thread-safe_singleton article.
-
[quote author="SABROG" date="1282146241"]Why reference to T must be const, what if user want change internal state of class?[/quote]
Yep, you are right. My fault.
[quote author="SABROG" date="1282146241"]call_once it's thread-safe alternative for Double-Checked Locking pattern.[/quote]
I read about it :). What I meant is towrite just a few words of description on that page, so there is not just naked code.