Olly Betts <[email protected]> writes:

>
> Presumably this gets called from a catch block on the exception just
> caught in which case you can rethrow the current exception with just
> `throw;` (we do this in xapian-bindings to avoid a lot of duplicate
> code to translate a C++ exception to something suitable in the target
> language).  I don't know if that's actually better than explicitly
> throwing the exception object again like you showed.

Ah right, thanks for the pointer. I see XapianExceptionHandler in
xapian-bindings/generate-generic-exceptions does essentially what I
proposed, except with the expression-less throw you mention. I guess
that makes me lean towards this solution unless convinced otherwise.

d
_______________________________________________
notmuch mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to