git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/simgrid/simgrid/trunk@1759
48e7efb5-ca39-0410-a469-
dd3cf9ba447f
/* the static and dynamic initializers for a context structure */
#define XBT_CTX_INITIALIZER \
/* the static and dynamic initializers for a context structure */
#define XBT_CTX_INITIALIZER \
- { NULL, 0, { /* content */ NULL, 0, 0, \
+ { NULL, 0, { /* content */ NULL, unknown_error, 0, \
/* throw point*/ NULL, NULL, NULL, 0, NULL,\
/* backtrace */ {NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL},0 } }
#define XBT_CTX_INITIALIZE(ctx) \
/* throw point*/ NULL, NULL, NULL, 0, NULL,\
/* backtrace */ {NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL},0 } }
#define XBT_CTX_INITIALIZE(ctx) \
/** @brief the block for catching (ie, deal with) an exception
* @hideinitializer
*/
/** @brief the block for catching (ie, deal with) an exception
* @hideinitializer
*/
+#ifdef __cplusplus
+# define XBT_EX_T_CPLUSPLUSCAST (xbt_ex_t&)
+#else
+# define XBT_EX_T_CPLUSPLUSCAST
+#endif
+
#define CATCH(e) \
else { \
} \
#define CATCH(e) \
else { \
} \
__xbt_ex_ctx_ptr->ctx_mctx = __ex_mctx_en; \
} \
if ( !(__xbt_ex_ctx()->ctx_caught) \
__xbt_ex_ctx_ptr->ctx_mctx = __ex_mctx_en; \
} \
if ( !(__xbt_ex_ctx()->ctx_caught) \
- || ((e) = __xbt_ex_ctx()->ctx_ex, 0)) { \
+ || ((e) = XBT_EX_T_CPLUSPLUSCAST __xbt_ex_ctx()->ctx_ex, 0)) { \