my_global.h:
Define cxa_pure_virtual to print error message and DBUG_ASSERT: calls to pure virtual methods should not go unnoticed.
This commit is contained in:
parent
6c996daa91
commit
664329b565
@ -213,7 +213,11 @@ C_MODE_END
|
|||||||
|
|
||||||
/* Fix problem when linking c++ programs with gcc 3.x */
|
/* Fix problem when linking c++ programs with gcc 3.x */
|
||||||
#ifdef DEFINE_CXA_PURE_VIRTUAL
|
#ifdef DEFINE_CXA_PURE_VIRTUAL
|
||||||
#define FIX_GCC_LINKING_PROBLEM extern "C" { int __cxa_pure_virtual() {return 0;} }
|
#define FIX_GCC_LINKING_PROBLEM \
|
||||||
|
extern "C" { int __cxa_pure_virtual() {\
|
||||||
|
DBUG_ASSERT("Pure virtual method called." == "Aborted");\
|
||||||
|
return 0;\
|
||||||
|
} }
|
||||||
#else
|
#else
|
||||||
#define FIX_GCC_LINKING_PROBLEM
|
#define FIX_GCC_LINKING_PROBLEM
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user