This source file contains documentation only.
#define OMNI_DEBUG |
Enable/disable DEBUG mode.
This macro is used to enable or disable DEBUG mode. If it defined to nonzero value DEBUG mode is enabled, otherwise DEBUG mode is disabled.
If OMNI_DEBUG macro is not quite defined, then it is defined automatically:
Note: OMNI_DEBUG should be defined to integral value (1 or 0). So definition "/DOMNI_DEBUG" will not properly work (DEBUG mode will be disabled). Instead always use the following definitions: "/DOMNI_DEBUG=1" or "/DOMNI_DEBUG=0".
#define OMNI_DEBUG_CODE | ( | code | ) |
Custom code in DEBUG mode.
This macro is used to insert custom code in DEBUG mode only (i.e. if OMNI_DEBUG is defined to nonzero value). The following two approach are equivalent, but second is shorten.
void f1(int x) { #if OMNI_DEBUG if (x < 0) error(); #endif // ... }
void f2(int x) { OMNI_DEBUG_CODE(if (x < 0) error()); // ... }
First approach (in function f1) is recommended for a debug code with complex multiline code. Second approach (in function f2) is recommended for a short (single line) debug code.
code | Custom debug code. |
#define OMNI_MT |
Enable/disable MULTI-THREAD mode.
This macro is used to enable or disable MULTI-THREAD mode. If it defined to nonzero value MULTI-THREAD mode is enabled, otherwise MULTI-THREAD mode is disabled.
If OMNI_MT macro is not quite defined, then it is defined automatically:
Note: OMNI_MT should be defined to integral value (1 or 0). So definition "/DOMNI_MT" will not properly work (MULTI-THREAD mode will be disabled). Instead always use the following definitions: "/DOMNI_MT=1" or "/DOMNI_MT=0".
For MS Visual C++ 2005 OMNI_MT macro is automatically defined to nonzero value.
#define OMNI_MT_CODE | ( | code | ) |
Custom code in MULTI-THREAD mode.
This macro is used to insert custom code in MULTI-THREAD mode only (i.e. if OMNI_MT is defined to nonzero value). The following two approach are equivalent, but second is shorten.
void f1() { #if OMNI_MT _lock(); #endif // ... #if OMNI_MT _unlock(); #endif }
void f2() { OMNI_MT_CODE(_lock()); // ... OMNI_MT_CODE(_unlock()); }
First approach (in function f1) is recommended for a multithread code with complex multiline code. Second approach (in function f2) is recommended for a short (single line) multithread code.
code | Custom multithread code. |
#define OMNI_UNICODE |
Enable/disable UNICODE mode.
This macro is used to enable or disable UNICODE mode. If it defined to nonzero value UNICODE mode is enabled, otherwise UNICODE mode is disabled.
If OMNI_UNICODE macro is not quite defined, then it is defined automatically:
Note: OMNI_UNICODE should be defined to integral value (1 or 0). So definition "/DOMNI_UNICODE" will not properly work (UNICODE mode will be disabled). Instead always use the following definitions: "/DOMNI_UNICODE=1" or "/DOMNI_UNICODE=0".
#define OMNI_FIX_FOR_SCOPE |
Fix for operator's scope.
If this macro is defined, then for operator's scope will be changed as follows:
#define for if (false) {} else for
For some compilers (MS Visual C++ 6.0) OMNI_FIX_FOR_SCOPE macro is automatically defined.
#define OMNI_USE_MKL |
Enable/disable using Intel MKL math library.
TODO: Intel MKL math library using detail description.
#define OMNI_USE_ATLAS |
Enable/disable using ATLAS math library.
TODO: ATLAS math library using detail description.
#define OMNI_SHOW_REMARK |
Show remark messages.
If this macro is defined, then during compiling OMNI library some remark messages will be shown. For example: DEBUG mode enable/disable status, MULTI-THREAD mode enable/disable status, etc.
>defs.cpp >OMNI remark: debug mode disabled >OMNI remark: multi-thread mode enabled
#define OMNI_EXCEPTION_SPEC |
Use strict exception specifiers.
TODO: detail exception specifiers description.