#ifdef _MSC_VER // Microsoft Visual C++ -- warning level 4
#pragma warning( disable : 4611) /* interaction between '_setjmp' and C++ object destruction is non-portable */
/* setjmp should not be implemented with 'catch' */
#endif
//! Use QH_TRY_ or QH_TRY_NOTHROW_ to call a libqhull_r routine that may invoke qh_errexit()
//! QH_TRY_(qh){...} qh->NOerrexit=true;
//! No object creation -- longjmp() skips object destructors
//! To test for error when done -- qh->maybeThrowQhullMessage(QH_TRY_status);
//! Use the same compiler for QH_TRY_, libqhullcpp, and libqhull_r. setjmp() is not portable between compilers.
#define QH_TRY_ERROR 10071
#define QH_TRY_(qh) \
int QH_TRY_status; \
if(qh->NOerrexit){ \
qh->NOerrexit= False; \
QH_TRY_status= setjmp(qh->errexit); \
}else{ \
throw QhullError(QH_TRY_ERROR, "Cannot invoke QH_TRY_() from inside a QH_TRY_. Or missing 'qh->NOerrexit=true' after previously called QH_TRY_(qh){...}"); \
} \
if(!QH_TRY_status)
#define QH_TRY_NO_THROW_(qh) \
int QH_TRY_status; \
if(qh->NOerrexit){ \
qh->NOerrexit= False; \
QH_TRY_status= setjmp(qh->errexit); \
}else{ \
QH_TRY_status= QH_TRY_ERROR; \
} \
if(!QH_TRY_status)
namespaceorgQhull{
#//!\name Defined here
//! QhullQh -- Qhull's global data structure, qhT, as a C++ class
classQhullQh;
//! POD type equivalent to qhT. No virtual members
classQhullQh:publicqhT{
#//!\name Constants
#//!\name Fields
private:
intqhull_status;//!< qh_ERRnone if valid
std::stringqhull_message;//!< Returned messages from libqhull_r
std::ostream*error_stream;//!< overrides errorMessage, use appendQhullMessage()
std::ostream*output_stream;//!< send output to stream
doublefactor_epsilon;//!< Factor to increase ANGLEround and DISTround for hyperplane equality
booluse_output_stream;//!< True if using output_stream