Use C++ exception model in D

Iain Buclaw ibuclaw at gdcproject.org
Wed Apr 9 07:32:56 PDT 2014


On 9 April 2014 14:54, Marco Leise <Marco.Leise at gmx.de> wrote:
> Am Wed, 9 Apr 2014 23:11:08 +1000
> schrieb "Daniel Murphy" <yebbliesnospam at gmail.com>:
>
>> "David Nadlinger"  wrote in message
>> news:bivyxqzewidjylastzbs at forum.dlang.org...
>>
>> > Sure, one way to go about this would be to just sit down and implement a
>> > common ABI in GDC and LDC (hackathon at London/Zürich/... anyone?) and then
>> > hope that some random contributor turns up later on and fixes DMD to
>> > conform to the standard we agreed on. But this does not necessarily strike
>> > me as a productive gamble...
>>
>> You could always go the other way and change GDC and LDC to match what DMD
>> does. :)
>
> And precisely that is not always possible. E.g. GCC developers
> have decided against "naked" asm functions. And this

Naked exists, just not for x86.  :o)

> out-contract-accessing-caller-scope thing that David mentioned
> looks like it could pose trouble with LLVM and/or GCC.

It *does* pose trouble.  I've just never pointed it out before because
GDC builds the stack frame in the front-end (the middle end never got
it right anyway because of delegates).

The one thing we *do* rely on is that the D front-end marks all
closure vars correctly, even if a closure is not required for the
function.


> A common ground has to be found that likely changes the ABI in
> all 3 compilers. DMD is actually least restricted by the lack
> of vetoing "upstream" developers :)
>

I have only vetoed features that are tied to a specific architecture.
This is not unreasonable in my eyes.



More information about the Digitalmars-d mailing list