[Dlang-internal] including "globals.h" in "mscoffobj.c"

Benjamin Thaut via Dlang-internal dlang-internal at puremagic.com
Sun Jul 16 10:56:34 PDT 2017


Currently when compiling dmd it seems to be setup so that 
"globals.h" can not be included from "mscoffobj.c". I'm wondering 
now if this is intentional. If it is intentional how would one 
access certain flags which are part of the globals.params struct 
inside mscoffobj.c?

I can think of two ways right now
1) Add additional arguments to MsCoffObj::init
2) Pull out the condition into the dmd frontend (this would be a 
lot of boilerplate code to add in this case)

In case details are needed look at this file and search for 
"global.params": 
https://github.com/Ingrater/dmd/blob/DllSupportD2/src/backend/mscoffobj.c

Kind Regards
Benjamin Thaut


More information about the Dlang-internal mailing list