From a65ff4094a577a2beb082d17684fd7235b530fc0 Mon Sep 17 00:00:00 2001 From: Julien Schueller Date: Sat, 26 Oct 2024 13:19:01 +0200 Subject: [PATCH] SWIG: Fix unknown std::runtime_error --- src/swig/nlopt.i | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/swig/nlopt.i b/src/swig/nlopt.i index b72de47b..175b5b8f 100644 --- a/src/swig/nlopt.i +++ b/src/swig/nlopt.i @@ -12,6 +12,10 @@ can be found at the NLopt web page: http://ab-initio.mit.edu/nlopt" #include "nlopt.hpp" %} +#define SWIG_STD_EXCEPTIONS_AS_CLASSES + +%include "std_string.i" +%include "std_except.i" %include "std_vector.i" namespace std { %template(nlopt_doublevector) vector;