On 12/14/2013 6:08 AM, Iain Buclaw wrote:
The implementation of which existed in GDC first, and was released as dual GPL/BSD license to allow into LDC devs to use and improve (they added 64bit assembler support for instance, years before DMD got 64bit support),
I didn't know this, thanks for telling me.
and then subsequently dropped from GDC for a number of valid reasons: 1) Transition towards making a platform/target agnostic frontend implementation. 2) Don't and will never implement the DMD-style calling convention, so all inline assembly in druntime and phobos actually doesn't work with GDC - there's actually a bug report about GDC incorrectly pre-defining D_InlineAsm and friends because of this.
dmd's works on multiple platforms and uses version statements to account for ABI differences. It's still easier than having a different syntax.
3) It is a really big WAT on having two conflicting styles, one for x86, another for everything else.
gcc gets them wrong for everything else, too :-)
4) This and other x86 hacks were a problem with code reviewers from GCC.
I can understand that.
Though saying that, whilst DMD-style was not ideal, neither is GDC-style either, as it requires parser changes, and adds a new class to handle them in the frontend.
