From: Morgan Deters Date: Tue, 26 Nov 2013 21:36:52 +0000 (-0500) Subject: Fix C++-to-Java exception translation. X-Git-Tag: cvc5-1.0.0~7240 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=18421d3a95b42e85dcd7cb5935d4b2519b168007;p=cvc5.git Fix C++-to-Java exception translation. --- diff --git a/src/cvc4.i b/src/cvc4.i index 6e9380146..da15d4b5d 100644 --- a/src/cvc4.i +++ b/src/cvc4.i @@ -97,13 +97,15 @@ std::set CVC4::JavaInputStreamAdapter::s_adapters; // Create a mapping from C++ Exceptions to Java Exceptions. // This is in a couple of throws typemaps, simply because it's sensitive to SWIG's concept of which namespace we're in. %typemap(throws) Exception %{ - std::string name = "edu/nyu/acsys/$1_type"; + std::string name = "edu/nyu/acsys/CVC4/$1_type"; + /* size_t i = name.find("::"); if(i != std::string::npos) { size_t j = name.rfind("::"); assert(i <= j); name.replace(i, j - i + 2, "/"); } + */ jclass clazz = jenv->FindClass(name.c_str()); assert(clazz != NULL && jenv->ExceptionOccurred() == NULL); jmethodID method = jenv->GetMethodID(clazz, "", "(JZ)V");