This is to give more information about SWIG as it is needed for the understanding of the use of SWIG for D. These are features of SWIG which have not been modified for D.
It is possible to maintain a single header file for a particular C or C++ source, which can be run for different target languages. SWIG supports a lot of target languages e.g. Tcl, ruby, perl. For each of them there is a defined constant which can be used to include or exclude code depending on the target language.
- for D it is SWIGDMD
For full documentation on SWIG (other than for D) see SWIG.