Including windows.h
Walter Bright
newshound2 at digitalmars.com
Tue Jun 23 04:00:02 UTC 2026
Every operating system vendor suffers from the disease of feeling compelled to
add all kinds of ding-dong extensions to their C compiler, all different from
every other operating system, and weld them into their ding-dong system .h files.
(The correct way to do this is to make the .h files use Standard C, and relegate
the ding-dongs to the implementation files that nobody ever needs to see.)
With D, this has resulted in a lot of ugly hacks and workarounds for the
ding-dong constructions. You can see these in druntime/src/__importc_builtins.di
and druntime/src/importc.h.
They can help in showing how to deal with windows.h.
An alternative you can try is windows.d in druntime.
If you're blocked, the thing to do is file an issue for each item, and then the
D community can help out.
More information about the Digitalmars-d
mailing list