1 %include <typemaps/exception.swg> 2 3 %insert("runtime") { 4 %define_as(SWIG_exception(code, msg), %block(%error(code, msg);)) 5 } 6