On Friday, 12 September 2014 at 22:50:50 UTC, Sean Kelly wrote:
I'm hoping it's simply a matter of sticking the right data in a
lookup table and letting the C++ runtime figure out what the
proper match is for us.
I suggest familiarizing yourself with how libunwind works. Look
up personality routines, or even just peruse GCC's
libstdc++-v3/libsupc++/eh_personality.cc or Clang's
libcxxabi/src/cxa_{exception, personality}.cpp.
D currently has a custom mechanism for throwing on non-Windows
platforms, but it may be worth switching to the established C++
approach, provided we can do so without losing anything (and
this is a big "if" given how we implicitly chain exceptions).
s/D/DMD/. And yes, LDC does implement exception chaining.