Don Wrote: > Jeremie Pelletier wrote: > > Well I've decided to get a look at the dmd2 source and see what I can > > contribute to it, only to notice it is very VC++ unfriendly. After a > > few hours of work, I finally got it to compile, and it works great, > > for the most part. > > > > VC++ has no real support for long double; it supports the syntax as > > distinct types but they are implemented as double precision, not > > extended precision. There are no stdint.h and fenv.h headers, I found > > isnan() in float.h but I had to leave out backend/strtold.c for now, > > there was no unresolved references from this. alloca() was also found > > in malloc.h, not stdlib.h. The joys of not using a C99 compliant > > compiler heh. I also couldn't get the compiler to compile *.c as C++, > > even with the /TP switch (Compile as C++), I had to rename every file > > to *.cpp. > > > > Other than that, it was standard compilation, I disabled a few > > warnings to not get my output flooded, defined MARS, __I86__ and _DH, > > generated the different table files, and compiled, all from within > > the IDE. > > What are the advantages of VC++? Just the browsing?
It has one of the most powerful IDEs I have seen so far, and its debugging support is amazing. I also think its a good idea to make the dmd source compilable on a few different compilers, it will allow a wider range of developers to contribute to it in the long run. > > Jumping back in C++ reminded me why I loved D so much, I will > > definitely start working on, or help developing it if already > > planned, a D port of dmd once the spec gets stable. > > Oh yeah. Looking at the source, I keep thinking, "this would be SO much > easier in D!". > Interestingly since DMD has extern(C++), it ought to be possible to > convert a single module to D, and still link it in... > > > In any ways, I am wondering where I can submit my changes for review, > > since I doubt there is any public access to the repository on > > dsource, and I would very much like to contribute to the D > > programming language. > > It'd be fantastic if you could help. > I've just been submitting my patches to Bugzilla. Walter sends me his > source from time to time. If you get active enough with patches we'll > make a better arrangement. It's only yesterday that Walter made a commit > to the repository for the first time, so at least he has it set up now <g>. > > I suggest that to start off, you look at the .stringof bugs. .stringof > has a reputation as one of the most buggy features in the compiler, but > I think it's only because of neglect rather than being particularly > complicated. Sure, I'll give it a look, I need to get familiar with the code structure anyways :)