Subj : Re: Can C++ local static objects be made thread safe? To : comp.programming.threads From : David Schwartz Date : Tue Jan 18 2005 05:28 pm "Marcin 'Qrczak' Kowalczyk" wrote in message news:87r7ki5mel.fsf@qrnik.zagroda... > IMHO if the compiler supports threads, it should act as if it > implemented a hypothetical extended C++ standard with threads. > A reasonable semantics of static variables in functions in > multithreaded C++ would require locking. Lock what exactly? How should the compiler know what the constructor might conflict with and what locks might be appropriate? Conflicting with another possible instantiation of the same object is not the only possible conflict. DS .