On Friday, 16 May 2014 at 19:17:05 UTC, Dicebot wrote:
On Friday, 16 May 2014 at 19:05:25 UTC, Tom Browder via
Digitalmars-d-learn wrote:
On Fri, May 16, 2014 at 1:05 PM, Gary Willoughby via
Digitalmars-d-learn <digitalmars-d-learn@puremagic.com> wrote:
...
Then take a look at one of my projects in which i've ported C
headers to D.
https://github.com/nomad-software/tcltk
I notice your binding source files have a ".d" suffix. Is
that the
preferred convention? I'm asking because I saw ".di" used on
several
D Wiki pages.
Best,
-Tom
Using .di is more idiomatic as those are supposed to denote
declaration-only interface files (with no implementation). In
practice it makes almost no difference though so many people
use plain .d by habit.
That's right. I always use .d files when porting C headers
because i just see them as regular D code. I like to classify .di
files as D 'headers' generated from pure D libraries (using the
-H compiler switch). That's just my opinion though and to be
honest i don't think it matters. :)