Example code showing how to use SWIG to port C++ libraries which throw exceptions to go libraries which return errors