www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 19492] New: Warn / error if shared static ctors haven't

https://issues.dlang.org/show_bug.cgi?id=19492

          Issue ID: 19492
           Summary: Warn / error if shared static ctors haven't finished
                    and we start running thread-local static ctors
           Product: D
           Version: D2
          Hardware: x86_64
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P1
         Component: druntime
          Assignee: nobody puremagic.com
          Reporter: dhasenan gmail.com

https://forum.dlang.org/thread/wubzutckdlxxojyyeinq forum.dlang.org

User started a thread in a shared static constructor. This predictably started
running thread-local static constructors before the shared static constructors
finished.

It would be useful to have it be an error to start thread-local static
constructors before shared static constructors finish.

--
Dec 15 2018