test_broadcast: derive from std::exception

This commit is contained in:
Arne Morten Kvarving committed 2026-06-10 11:06:17 +02:00
1 parent 6c91565f1f
commit 37c2c316c6
1 file changed
+6 -1
+6 -1
View File
@@ -29,12 +29,17 @@
#include <opm/simulators/utils/MPISerializer.hpp>
#include <dune/common/parallel/mpihelper.hh>
#include <exception>
#include <numeric>
#if HAVE_MPI
struct MPIError
struct MPIError : public std::exception
{
MPIError(std::string s, int e) : errorstring(std::move(s)), errorcode(e){}
const char* what() const noexcept override
{ return errorstring.c_str(); }
std::string errorstring;
int errorcode;
};