On 2018-02-12 02:27, Walter Bright wrote:
Know what is a heavyweight problem worth our while? Having dmd be able
to directly read C .h files, so the poor user does not have to manually
We've already got a huge chunk of that problem solved. The Digital Mars
C/C++ front end is now Boost licensed. It can be used. It's already been
converted to D! The preprocessor in it is a bit dated and a bit too
specific to Windows - but we've got Warp now!
Replace the preprocessor in dmc++ with Warp, slice off the back end, and
make it a module that dmd can import.
Wouldn't it be nice to support:
import stdio.h; // Look, Ma! C headers!
There are some intractable issues, and it may be impossible to get 100%
to "it just works", but looking past that it might be a huge win for us.
Here you go . It's a bit outdated now, from 2013, but it worked back