www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 21977] New: importC: Global declarations are thread-local by

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

          Issue ID: 21977
           Summary: importC: Global declarations are thread-local by
                    default
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Severity: major
          Priority: P1
         Component: dmd
          Assignee: nobody puremagic.com
          Reporter: ibuclaw gdcproject.org

In D all globals and static variables are thread-local unless explicitly
otherwise.  In C, it's the opposite.

---
int signgam;
char *program_invocation_name;
---

$ objdump -t issue.o

issue.o:     file format elf64-x86-64

SYMBOL TABLE:
0000000000000000 g       .tbss  0000000000000004 signgam
0000000000000008 g       .tbss  0000000000000008 program_invocation_name

--
May 25 2021