Catching C++ Exceptions in D

Walter Bright via Digitalmars-d digitalmars-d at puremagic.com
Tue Jan 5 10:49:45 PST 2016


On 1/5/2016 10:22 AM, Jakob Ovrum wrote:
>> C++ exceptions cannot be thrown from D. If you must throw a C++ exception,
>> write and call a C++ function to do it.
>
> Because C++-throw copies the exception and thus slices base class references,
> this is actually quite inconvenient. There's no One Helper Function that can
> handle a whole swath of cases. Just wanted to mention it, not saying this should
> be an important or priority feature, it's just an inconvenience after all.

It's just a limitation for now in order to get things moving.



More information about the Digitalmars-d mailing list