TODO skip_remaining überall, oder nur wenn es eh schon gemacht wird?

bool skip_remaining = false;
std::exception_ptr tmp_exception;


in parallel / for / section / critical / ...

if (skip_remaining) continue;
#ifndef NCATCH
try {
#endif


#ifndef NCATCH
} catch(const std::exception& e) {
    tmp_exception = std::current_exception();
    skip_remaining = true;
    #pragma omp flush(skip_remaining)
}
#endif



Nachdem man aus allem raus ist

if (tmp_exception != std::exception_ptr()) std::rethrow_exception(tmp_exception);
