Conversation
Notices
-
Wow, #dpp, the D preprocessor.
https://code.dlang.org/packages/dpp
It takes an almost-D file that contains C-#includes, inserts those, translates any prototypes into the right D prototype in an extern(C) block, runs the result through the real cpp to expand any macros, and that becomes a D file that the normal compiler can compile.
Sounds crazy, but apparently it's been tested to work for calling libcurl, openssl, nanomsg and a few others, and that's still early days. Kindasorta works with C++ if it's basically a C-compatible subset.
!dlang