*Massive cleanup (\n\n -> \n, *\n -> \n, cleanup for(...) to for (...), and some other cleanups by hand)
*Fix a possible crash in Spell::DoAllEffectOnTarget --HG-- branch : trunk
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
// -*- C++ -*-
|
||||
|
||||
//==========================================================================
|
||||
/**
|
||||
* @file config-macros.h
|
||||
@@ -17,19 +16,15 @@
|
||||
* language sources.
|
||||
*/
|
||||
//==========================================================================
|
||||
|
||||
#ifndef ACE_CONFIG_MACROS_H
|
||||
#define ACE_CONFIG_MACROS_H
|
||||
|
||||
#ifdef _WIN32
|
||||
#include "ace/config-win32.h"
|
||||
#else
|
||||
#include "ace/config.h"
|
||||
#endif //_WIN32
|
||||
|
||||
#include "ace/Version.h"
|
||||
#include "ace/Versioned_Namespace.h"
|
||||
|
||||
// ACE_HAS_TLI is used to decide whether to try any XTI/TLI functionality
|
||||
// so if it isn't set, set it. Capabilities and differences between
|
||||
// XTI and TLI favor XTI, but when deciding to do anything, as opposed to
|
||||
@@ -39,9 +34,7 @@
|
||||
# define ACE_HAS_TLI
|
||||
# endif /* ACE_HAS_XTI */
|
||||
#endif /* ACE_HAS_TLI */
|
||||
|
||||
#define ACE_BITS_PER_ULONG (8 * sizeof (u_long))
|
||||
|
||||
#if !defined (ACE_OSTREAM_TYPE)
|
||||
# if defined (ACE_LACKS_IOSTREAM_TOTALLY)
|
||||
# define ACE_OSTREAM_TYPE FILE
|
||||
@@ -49,7 +42,6 @@
|
||||
# define ACE_OSTREAM_TYPE ostream
|
||||
# endif /* ! ACE_LACKS_IOSTREAM_TOTALLY */
|
||||
#endif /* ! ACE_OSTREAM_TYPE */
|
||||
|
||||
#if !defined (ACE_DEFAULT_LOG_STREAM)
|
||||
# if defined (ACE_LACKS_IOSTREAM_TOTALLY)
|
||||
# define ACE_DEFAULT_LOG_STREAM 0
|
||||
@@ -57,7 +49,6 @@
|
||||
# define ACE_DEFAULT_LOG_STREAM (&cerr)
|
||||
# endif /* ! ACE_LACKS_IOSTREAM_TOTALLY */
|
||||
#endif /* ! ACE_DEFAULT_LOG_STREAM */
|
||||
|
||||
// These two are only for backward compatibility. You should avoid
|
||||
// using them if not necessary.
|
||||
#if !defined (ACE_LACKS_DEPRECATED_MACROS)
|
||||
@@ -70,12 +61,10 @@
|
||||
*/
|
||||
# define ACE_SYNCH_2 ACE_SYNCH_USE
|
||||
#endif
|
||||
|
||||
// For Win32 compatibility...
|
||||
# if !defined (ACE_WSOCK_VERSION)
|
||||
# define ACE_WSOCK_VERSION 0, 0
|
||||
# endif /* ACE_WSOCK_VERSION */
|
||||
|
||||
# if defined (ACE_MT_SAFE) && (ACE_MT_SAFE != 0)
|
||||
# define ACE_MT(X) X
|
||||
# if !defined (_REENTRANT)
|
||||
@@ -84,22 +73,18 @@
|
||||
# else
|
||||
# define ACE_MT(X)
|
||||
# endif /* ACE_MT_SAFE */
|
||||
|
||||
# if defined (ACE_HAS_PURIFY)
|
||||
# define ACE_INITIALIZE_MEMORY_BEFORE_USE
|
||||
# endif /* ACE_HAS_PURIFY */
|
||||
|
||||
# if defined (ACE_HAS_VALGRIND)
|
||||
# define ACE_INITIALIZE_MEMORY_BEFORE_USE
|
||||
# endif /* ACE_HAS_VALGRIND */
|
||||
|
||||
#if !defined (ACE_LACKS_DEPRECATED_MACROS)
|
||||
/**
|
||||
* @deprecated The @c ACE_HAS_USING macros are deprecated
|
||||
*/
|
||||
# define ACE_USING using
|
||||
#endif /* !ACE_LACKS_DEPRECATED_MACROS */
|
||||
|
||||
#if !defined (ACE_LACKS_DEPRECATED_MACROS)
|
||||
/**
|
||||
* @deprecated The @c ACE_TYPENAME macros is deprecated. Use standard
|
||||
@@ -107,7 +92,6 @@
|
||||
*/
|
||||
# define ACE_TYPENAME typename
|
||||
#endif /* !ACE_LACKS_DEPRECATED_MACROS */
|
||||
|
||||
#if !defined (ACE_LACKS_DEPRECATED_MACROS)
|
||||
/**
|
||||
* @deprecated The @c ACE_TEMPLATE_SPECIALIZATION and
|
||||
@@ -118,26 +102,21 @@
|
||||
# define ACE_TEMPLATE_SPECIALIZATION template<>
|
||||
# define ACE_TEMPLATE_CLASS_MEMBER_SPECIALIZATION
|
||||
#endif /* !ACE_LACKS_DEPRECATED_MACROS */
|
||||
|
||||
// =========================================================================
|
||||
// Perfect Multicast filting refers to RFC 3376, where a socket is only
|
||||
// delivered dgrams for groups joined even if it didn't bind the group
|
||||
// address. We turn this option off by default, although most OS's
|
||||
// except for Windows and Solaris probably lack perfect filtering.
|
||||
// =========================================================================
|
||||
|
||||
# if !defined (ACE_LACKS_PERFECT_MULTICAST_FILTERING)
|
||||
# define ACE_LACKS_PERFECT_MULTICAST_FILTERING 0
|
||||
# endif /* ACE_LACKS_PERFECT_MULTICAST_FILTERING */
|
||||
|
||||
// =========================================================================
|
||||
// Enable/Disable Features By Default
|
||||
// =========================================================================
|
||||
|
||||
# if !defined (ACE_HAS_POSITION_INDEPENDENT_POINTERS)
|
||||
# define ACE_HAS_POSITION_INDEPENDENT_POINTERS 1
|
||||
# endif /* ACE_HAS_POSITION_INDEPENDENT_POINTERS */
|
||||
|
||||
# if !defined (ACE_HAS_PROCESS_SPAWN)
|
||||
# if !defined (ACE_LACKS_FORK) || \
|
||||
(defined (ACE_WIN32) && !defined (ACE_HAS_PHARLAP)) || \
|
||||
@@ -145,31 +124,25 @@
|
||||
# define ACE_HAS_PROCESS_SPAWN 1
|
||||
# endif
|
||||
# endif /* ACE_HAS_PROCESS_SPAWN */
|
||||
|
||||
# if !defined (ACE_HAS_DYNAMIC_LINKING)
|
||||
# if defined (ACE_HAS_SVR4_DYNAMIC_LINKING) || defined (ACE_WIN32) || defined (ACE_VXWORKS) || defined (__hpux)
|
||||
# define ACE_HAS_DYNAMIC_LINKING 1
|
||||
# endif
|
||||
# endif /* ACE_HAS_DYNAMIC_LINKING */
|
||||
|
||||
# if defined (ACE_USES_FIFO_SEM)
|
||||
# if defined (ACE_HAS_POSIX_SEM) || defined (ACE_LACKS_MKFIFO) || defined (ACE_LACKS_FCNTL)
|
||||
# undef ACE_USES_FIFO_SEM
|
||||
# endif
|
||||
# endif /* ACE_USES_FIFO_SEM */
|
||||
|
||||
// =========================================================================
|
||||
// RCSID Macros
|
||||
// =========================================================================
|
||||
|
||||
// By default, DO NOT include RCS Id strings in object code.
|
||||
#if ! defined (ACE_USE_RCSID)
|
||||
# define ACE_USE_RCSID 0
|
||||
#endif /* #if ! defined (ACE_USE_RCSID) */
|
||||
|
||||
#if (defined (ACE_USE_RCSID) && (ACE_USE_RCSID != 0))
|
||||
# if ! defined (ACE_RCSID)
|
||||
|
||||
// This hack has the following purposes:
|
||||
// 1. To define the RCS id string variable as a static char*, so
|
||||
// that there won't be any duplicate extern symbols at link
|
||||
@@ -178,7 +151,6 @@
|
||||
// file.
|
||||
// 3. To avoid warnings of the type "variable declared and never
|
||||
// used".
|
||||
|
||||
# define ACE_RCSID(path, file, id) \
|
||||
static inline const char* get_rcsid_ ## path ## _ ## file (const char*) \
|
||||
{ \
|
||||
@@ -186,33 +158,27 @@
|
||||
} \
|
||||
static const char* rcsid_ ## path ## _ ## file = \
|
||||
get_rcsid_ ## path ## _ ## file ( rcsid_ ## path ## _ ## file ) ;
|
||||
|
||||
# endif /* #if ! defined (ACE_RCSID) */
|
||||
#else
|
||||
|
||||
// RCS id strings are not wanted.
|
||||
# if defined (ACE_RCSID)
|
||||
# undef ACE_RCSID
|
||||
# endif /* #if defined (ACE_RCSID) */
|
||||
# define ACE_RCSID(path, file, id) /* noop */
|
||||
#endif /* #if (defined (ACE_USE_RCSID) && (ACE_USE_RCSID != 0)) */
|
||||
|
||||
// =========================================================================
|
||||
// INLINE macros
|
||||
//
|
||||
// These macros handle all the inlining of code via the .i or .inl files
|
||||
// =========================================================================
|
||||
|
||||
#if defined (ACE_LACKS_INLINE_FUNCTIONS) && !defined (ACE_NO_INLINE)
|
||||
# define ACE_NO_INLINE
|
||||
#endif /* defined (ACE_LACKS_INLINE_FUNCTIONS) && !defined (ACE_NO_INLINE) */
|
||||
|
||||
// ACE inlining has been explicitly disabled. Implement
|
||||
// internally within ACE by undefining __ACE_INLINE__.
|
||||
#if defined (ACE_NO_INLINE)
|
||||
# undef __ACE_INLINE__
|
||||
#endif /* ! ACE_NO_INLINE */
|
||||
|
||||
#if defined (__ACE_INLINE__)
|
||||
# define ACE_INLINE inline
|
||||
# if !defined (ACE_HAS_INLINED_OSCALLS)
|
||||
@@ -221,24 +187,20 @@
|
||||
#else
|
||||
# define ACE_INLINE
|
||||
#endif /* __ACE_INLINE__ */
|
||||
|
||||
#if !defined (ACE_LACKS_DEPRECATED_MACROS)
|
||||
// =========================================================================
|
||||
// EXPLICIT macro
|
||||
// =========================================================================
|
||||
|
||||
/**
|
||||
* @deprecated explicit is deprecated. ACE requires C++
|
||||
* "explicit" keyword support.
|
||||
*/
|
||||
# define ACE_EXPLICIT explicit
|
||||
#endif /* ACE_LACKS_DEPRECATED_MACROS */
|
||||
|
||||
#if !defined (ACE_LACKS_DEPRECATED_MACROS)
|
||||
// =========================================================================
|
||||
// MUTABLE macro
|
||||
// =========================================================================
|
||||
|
||||
/**
|
||||
* @deprecated ACE_MUTABLE is deprecated. ACE requires C++ "mutable"
|
||||
* keyword support.
|
||||
@@ -246,14 +208,12 @@
|
||||
# define ACE_MUTABLE mutable
|
||||
# define ACE_CONST_WHEN_MUTABLE const
|
||||
#endif /* ACE_LACKS_DEPRECATED_MACROS */
|
||||
|
||||
// ============================================================================
|
||||
// EXPORT macros
|
||||
//
|
||||
// Since Win32 DLL's do not export all symbols by default, they must be
|
||||
// explicitly exported (which is done by *_Export macros).
|
||||
// ============================================================================
|
||||
|
||||
// Win32 should have already defined the macros in config-win32-common.h
|
||||
#if !defined (ACE_HAS_CUSTOM_EXPORT_MACROS)
|
||||
# define ACE_Proper_Export_Flag
|
||||
@@ -264,29 +224,22 @@
|
||||
# define ACE_IMPORT_SINGLETON_DECLARE(SINGLETON_TYPE, CLASS, LOCK)
|
||||
#else
|
||||
// An export macro should at the very least have been defined.
|
||||
|
||||
# ifndef ACE_Proper_Import_Flag
|
||||
# define ACE_Proper_Import_Flag
|
||||
# endif /* !ACE_Proper_Import_Flag */
|
||||
|
||||
# ifndef ACE_EXPORT_SINGLETON_DECLARATION
|
||||
# define ACE_EXPORT_SINGLETON_DECLARATION(T)
|
||||
# endif /* !ACE_EXPORT_SINGLETON_DECLARATION */
|
||||
|
||||
# ifndef ACE_IMPORT_SINGLETON_DECLARATION
|
||||
# define ACE_IMPORT_SINGLETON_DECLARATION(T)
|
||||
# endif /* !ACE_IMPORT_SINGLETON_DECLARATION */
|
||||
|
||||
# ifndef ACE_EXPORT_SINGLETON_DECLARE
|
||||
# define ACE_EXPORT_SINGLETON_DECLARE(SINGLETON_TYPE, CLASS, LOCK)
|
||||
# endif /* !ACE_EXPORT_SINGLETON_DECLARE */
|
||||
|
||||
# ifndef ACE_IMPORT_SINGLETON_DECLARE
|
||||
# define ACE_IMPORT_SINGLETON_DECLARE(SINGLETON_TYPE, CLASS, LOCK)
|
||||
# endif /* !ACE_IMPORT_SINGLETON_DECLARE */
|
||||
|
||||
#endif /* !ACE_HAS_CUSTOM_EXPORT_MACROS */
|
||||
|
||||
// This is a whim of mine -- that instead of annotating a class with
|
||||
// ACE_Export in its declaration, we make the declaration near the TOP
|
||||
// of the file with ACE_DECLARE_EXPORT.
|
||||
@@ -299,16 +252,13 @@
|
||||
// Someday, when template libraries are supported, we made need ...
|
||||
// ACE_DECLARE_EXPORT(template class, sometemplate) <class TYPE, class LOCK>;
|
||||
# define ACE_DECLARE_EXPORT(TS,ID) TS ACE_Export ID
|
||||
|
||||
// ============================================================================
|
||||
// Cast macros
|
||||
//
|
||||
// These macros are used to choose between the old cast style and the new
|
||||
// *_cast<> operators
|
||||
// ============================================================================
|
||||
|
||||
# define ACE_sap_any_cast(TYPE) reinterpret_cast<TYPE> (const_cast<ACE_Addr &> (ACE_Addr::sap_any))
|
||||
|
||||
#if !defined (ACE_LACKS_DEPRECATED_MACROS)
|
||||
/**
|
||||
* @deprecated ACE_{static,reinterpret,dynamic,const}_cast@<@> is
|
||||
@@ -325,7 +275,6 @@
|
||||
# define ACE_static_cast_3_ref(TYPE, T1, T2, T3, EXPR) static_cast<TYPE<T1, T2, T3> &> (EXPR)
|
||||
# define ACE_static_cast_4_ref(TYPE, T1, T2, T3, T4, EXPR) static_cast<TYPE<T1, T2, T3, T4> &> (EXPR)
|
||||
# define ACE_static_cast_5_ref(TYPE, T1, T2, T3, T4, T5, EXPR) static_cast<TYPE<T1, T2, T3, T4, T5> &> (EXPR)
|
||||
|
||||
# define ACE_const_cast(TYPE, EXPR) const_cast<TYPE> (EXPR)
|
||||
# define ACE_const_cast_1_ptr(TYPE, T1, EXPR) const_cast<TYPE<T1> *> (EXPR)
|
||||
# define ACE_const_cast_2_ptr(TYPE, T1, T2, EXPR) const_cast<TYPE<T1, T2> *> (EXPR)
|
||||
@@ -337,7 +286,6 @@
|
||||
# define ACE_const_cast_3_ref(TYPE, T1, T2, T3, EXPR) const_cast<TYPE<T1, T2, T3> &> (EXPR)
|
||||
# define ACE_const_cast_4_ref(TYPE, T1, T2, T3, T4, EXPR) const_cast<TYPE<T1, T2, T3, T4> &> (EXPR)
|
||||
# define ACE_const_cast_5_ref(TYPE, T1, T2, T3, T4, T5, EXPR) const_cast<TYPE<T1, T2, T3, T4, T5> &> (EXPR)
|
||||
|
||||
# define ACE_reinterpret_cast(TYPE, EXPR) reinterpret_cast<TYPE> (EXPR)
|
||||
# define ACE_reinterpret_cast_1_ptr(TYPE, T1, EXPR) reinterpret_cast<TYPE<T1> *> (EXPR)
|
||||
# define ACE_reinterpret_cast_2_ptr(TYPE, T1, T2, EXPR) reinterpret_cast<TYPE<T1, T2> *> (EXPR)
|
||||
@@ -349,7 +297,6 @@
|
||||
# define ACE_reinterpret_cast_3_ref(TYPE, T1, T2, T3, EXPR) reinterpret_cast<TYPE<T1, T2, T3> &> (EXPR)
|
||||
# define ACE_reinterpret_cast_4_ref(TYPE, T1, T2, T3, T4, EXPR) reinterpret_cast<TYPE<T1, T2, T3, T4> &> (EXPR)
|
||||
# define ACE_reinterpret_cast_5_ref(TYPE, T1, T2, T3, T4, T5, EXPR) reinterpret_cast<TYPE<T1, T2, T3, T4, T5> &> (EXPR)
|
||||
|
||||
# define ACE_dynamic_cast(TYPE, EXPR) dynamic_cast<TYPE> (EXPR)
|
||||
# define ACE_dynamic_cast_1_ptr(TYPE, T1, EXPR) dynamic_cast<TYPE<T1> *> (EXPR)
|
||||
# define ACE_dynamic_cast_2_ptr(TYPE, T1, T2, EXPR) dynamic_cast<TYPE<T1, T2> *> (EXPR)
|
||||
@@ -362,7 +309,6 @@
|
||||
# define ACE_dynamic_cast_4_ref(TYPE, T1, T2, T3, T4, EXPR) dynamic_cast<TYPE<T1, T2, T3, T4> &> (EXPR)
|
||||
# define ACE_dynamic_cast_5_ref(TYPE, T1, T2, T3, T4, T5, EXPR) dynamic_cast<TYPE<T1, T2, T3, T4, T5> &> (EXPR)
|
||||
#endif /* ACE_LACKS_DEPRECATED_MACROS */
|
||||
|
||||
# if !defined (ACE_CAST_CONST)
|
||||
// Sun CC 4.2, for example, requires const in reinterpret casts of
|
||||
// data members in const member functions. But, other compilers
|
||||
@@ -373,14 +319,12 @@
|
||||
# define ACE_CAST_CONST
|
||||
# endif /* ! __SUNPRO_CC */
|
||||
# endif /* ! ACE_CAST_CONST */
|
||||
|
||||
// ============================================================================
|
||||
// Compiler Silencing macros
|
||||
//
|
||||
// Some compilers complain about parameters that are not used. This macro
|
||||
// should keep them quiet.
|
||||
// ============================================================================
|
||||
|
||||
#if !defined (ACE_UNUSED_ARG)
|
||||
# if defined (__GNUC__) && ((__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 2)))
|
||||
# define ACE_UNUSED_ARG(a) (void) (a)
|
||||
@@ -398,24 +342,20 @@
|
||||
# define ACE_UNUSED_ARG(a) (a)
|
||||
# endif /* ghs || __GNUC__ || ..... */
|
||||
#endif /* !ACE_UNUSED_ARG */
|
||||
|
||||
#if defined (_MSC_VER) || defined(__sgi) || defined (ghs) || defined (__DECCXX) || defined(__BORLANDC__) || defined (ACE_RM544) || defined (__USLC__) || defined (__DCC__) || defined (__PGI) || defined (__TANDEM) || (defined (__HP_aCC) && (__HP_aCC >= 60500))
|
||||
# define ACE_NOTREACHED(a)
|
||||
#else /* __sgi || ghs || ..... */
|
||||
# define ACE_NOTREACHED(a) a
|
||||
#endif /* __sgi || ghs || ..... */
|
||||
|
||||
// ============================================================================
|
||||
// ACE_ALLOC_HOOK* macros
|
||||
//
|
||||
// Macros to declare and define class-specific allocation operators.
|
||||
// ============================================================================
|
||||
|
||||
# if defined (ACE_HAS_ALLOC_HOOKS)
|
||||
# define ACE_ALLOC_HOOK_DECLARE \
|
||||
void *operator new (size_t bytes); \
|
||||
void operator delete (void *ptr);
|
||||
|
||||
// Note that these are just place holders for now. Some day they
|
||||
// may be be replaced by <ACE_Malloc>.
|
||||
# define ACE_ALLOC_HOOK_DEFINE(CLASS) \
|
||||
@@ -425,7 +365,6 @@
|
||||
# define ACE_ALLOC_HOOK_DECLARE struct __Ace {} /* Just need a dummy... */
|
||||
# define ACE_ALLOC_HOOK_DEFINE(CLASS)
|
||||
# endif /* ACE_HAS_ALLOC_HOOKS */
|
||||
|
||||
// ============================================================================
|
||||
/**
|
||||
* ACE_OSCALL* macros
|
||||
@@ -446,7 +385,6 @@
|
||||
* determined dynamically at run-time.
|
||||
*/
|
||||
// ============================================================================
|
||||
|
||||
#define ACE_OSCALL_RETURN(X,TYPE,FAILVALUE) \
|
||||
do \
|
||||
return (TYPE) (X); \
|
||||
@@ -455,7 +393,6 @@
|
||||
do \
|
||||
RESULT = (TYPE) (X); \
|
||||
while (0)
|
||||
|
||||
#if defined (ACE_WIN32)
|
||||
# define ACE_WIN32CALL_RETURN(X,TYPE,FAILVALUE) \
|
||||
do { \
|
||||
@@ -471,7 +408,6 @@
|
||||
ACE_OS::set_errno_to_last_error (); \
|
||||
} while (0)
|
||||
#endif /* ACE_WIN32 */
|
||||
|
||||
// The C99 security-improved run-time returns an error value on failure;
|
||||
// 0 on success.
|
||||
#if defined (ACE_HAS_TR24731_2005_CRT)
|
||||
@@ -481,25 +417,18 @@
|
||||
if (___ != 0) { errno = ___; RESULT = FAILVALUE; } \
|
||||
} while (0)
|
||||
#endif /* ACE_HAS_TR24731_2005_CRT */
|
||||
|
||||
// ============================================================================
|
||||
// Fundamental types
|
||||
// ============================================================================
|
||||
|
||||
#if defined (ACE_WIN32)
|
||||
|
||||
typedef HANDLE ACE_HANDLE;
|
||||
typedef SOCKET ACE_SOCKET;
|
||||
# define ACE_INVALID_HANDLE INVALID_HANDLE_VALUE
|
||||
|
||||
#else /* ! ACE_WIN32 */
|
||||
|
||||
typedef int ACE_HANDLE;
|
||||
typedef ACE_HANDLE ACE_SOCKET;
|
||||
# define ACE_INVALID_HANDLE -1
|
||||
|
||||
#endif /* ACE_WIN32 */
|
||||
|
||||
// Define the type that's returned from the platform's native thread
|
||||
// functions. ACE_THR_FUNC_RETURN is the type defined as the thread
|
||||
// function's return type, except when the thread function doesn't return
|
||||
@@ -518,7 +447,6 @@ typedef DWORD ACE_THR_FUNC_RETURN;
|
||||
typedef void* ACE_THR_FUNC_RETURN;
|
||||
# endif /* ACE_VXWORKS */
|
||||
typedef ACE_THR_FUNC_RETURN (*ACE_THR_FUNC)(void *);
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
@@ -527,14 +455,12 @@ typedef void (*ACE_THR_C_DEST)(void *);
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
typedef void (*ACE_THR_DEST)(void *);
|
||||
|
||||
// Now some platforms have special requirements...
|
||||
# if defined (ACE_VXWORKS) && !defined (ACE_HAS_PTHREADS)
|
||||
typedef FUNCPTR ACE_THR_FUNC_INTERNAL; // where typedef int (*FUNCPTR) (...)
|
||||
# else
|
||||
typedef ACE_THR_FUNC ACE_THR_FUNC_INTERNAL;
|
||||
# endif /* ACE_VXWORKS */
|
||||
|
||||
# ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
@@ -547,7 +473,6 @@ typedef ACE_THR_FUNC_RETURN (*ACE_THR_C_FUNC)(void *);
|
||||
# ifdef __cplusplus
|
||||
}
|
||||
# endif /* __cplusplus */
|
||||
|
||||
// ============================================================================
|
||||
// Macros for controlling the lifetimes of dlls loaded by ACE_DLL--including
|
||||
// all dlls loaded via the ACE Service Config framework.
|
||||
@@ -555,7 +480,6 @@ typedef ACE_THR_FUNC_RETURN (*ACE_THR_C_FUNC)(void *);
|
||||
// Please don't change these values or add new ones wantonly, since we use
|
||||
// the ACE_BIT_ENABLED, etc..., macros to test them.
|
||||
// ============================================================================
|
||||
|
||||
// Per-process policy that unloads dlls eagerly.
|
||||
#define ACE_DLL_UNLOAD_POLICY_PER_PROCESS 0
|
||||
// Apply policy on a per-dll basis. If the dll doesn't use one of the macros
|
||||
@@ -567,17 +491,14 @@ typedef ACE_THR_FUNC_RETURN (*ACE_THR_C_FUNC)(void *);
|
||||
// Default policy allows dlls to control their own destinies, but will
|
||||
// unload those that don't make a choice eagerly.
|
||||
#define ACE_DLL_UNLOAD_POLICY_DEFAULT ACE_DLL_UNLOAD_POLICY_PER_DLL
|
||||
|
||||
// Add this macro you one of your cpp file in your dll. X should
|
||||
// be either ACE_DLL_UNLOAD_POLICY_DEFAULT or ACE_DLL_UNLOAD_POLICY_LAZY.
|
||||
#define ACE_DLL_UNLOAD_POLICY(CLS,X) \
|
||||
extern "C" u_long CLS##_Export _get_dll_unload_policy (void) \
|
||||
{ return X;}
|
||||
|
||||
// ============================================================================
|
||||
// ACE_USES_CLASSIC_SVC_CONF macro
|
||||
// ============================================================================
|
||||
|
||||
// For now, default is to use the classic svc.conf format.
|
||||
#if !defined (ACE_USES_CLASSIC_SVC_CONF)
|
||||
# if defined (ACE_HAS_CLASSIC_SVC_CONF) && defined (ACE_HAS_XML_SVC_CONF)
|
||||
@@ -591,7 +512,6 @@ extern "C" u_long CLS##_Export _get_dll_unload_policy (void) \
|
||||
# define ACE_USES_CLASSIC_SVC_CONF 1
|
||||
# endif /* ACE_HAS_XML_SVC_CONF */
|
||||
#endif /* ACE_USES_CLASSIC_SVC_CONF */
|
||||
|
||||
// ============================================================================
|
||||
// Default svc.conf file extension.
|
||||
// ============================================================================
|
||||
@@ -600,17 +520,14 @@ extern "C" u_long CLS##_Export _get_dll_unload_policy (void) \
|
||||
#else
|
||||
# define ACE_DEFAULT_SVC_CONF_EXT ".conf.xml"
|
||||
#endif /* ACE_USES_CLASSIC_SVC_CONF && ACE_USES_CLASSIC_SVC_CONF == 1 */
|
||||
|
||||
// ============================================================================
|
||||
// Miscellaneous macros
|
||||
// ============================================================================
|
||||
|
||||
#if defined (ACE_USES_EXPLICIT_STD_NAMESPACE)
|
||||
# define ACE_STD_NAMESPACE std
|
||||
#else
|
||||
# define ACE_STD_NAMESPACE
|
||||
#endif
|
||||
|
||||
#if !defined (ACE_OS_String)
|
||||
# define ACE_OS_String ACE_OS
|
||||
#endif /* ACE_OS_String */
|
||||
@@ -623,7 +540,6 @@ extern "C" u_long CLS##_Export _get_dll_unload_policy (void) \
|
||||
#if !defined (ACE_OS_TLI)
|
||||
# define ACE_OS_TLI ACE_OS
|
||||
#endif /* ACE_OS_TLI */
|
||||
|
||||
// -------------------------------------------------------------------
|
||||
// Preprocessor symbols will not be expanded if they are
|
||||
// concatenated. Force the preprocessor to expand them during the
|
||||
@@ -632,6 +548,5 @@ extern "C" u_long CLS##_Export _get_dll_unload_policy (void) \
|
||||
#define ACE_PREPROC_CONCATENATE_IMPL(A,B) A ## B
|
||||
#define ACE_PREPROC_CONCATENATE(A,B) ACE_PREPROC_CONCATENATE_IMPL(A,B)
|
||||
// -------------------------------------------------------------------
|
||||
|
||||
#endif /* ACE_CONFIG_MACROS_H */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user