Patch for SourceForge Bug #1299 broke D and C#. Update D module to reflect these changes

NOTE: There are several test failures in the D test suite, so it is difficult to be entirely sure this does not break something.