00001 // $Id: String_Base_Const.cpp 77304 2007-02-21 22:29:49Z ossama $ 00002 00003 #include "ace/String_Base_Const.h" 00004 #include "ace/Numeric_Limits.h" 00005 00006 ACE_BEGIN_VERSIONED_NAMESPACE_DECL 00007 00008 ACE_String_Base_Const::size_type const ACE_String_Base_Const::npos = 00009 #if defined (AIX) //&& (defined (__xlC__) || defined (__IBMCPP__)) 00010 // Under some mixed shared/static linking conditions, this constant 00011 // will not be initialized at run-time if the 00012 // std::numeric_limits<>::max() trait is used on AIX/XLC++. 00013 // Workaround that problem by making it easier for the compiler to 00014 // realize it can set the constant at compile-time. 00015 static_cast<ACE_String_Base_Const::size_type> (-1); 00016 #else 00017 ACE_Numeric_Limits<ACE_String_Base_Const::size_type>::max (); 00018 #endif /* AIX */ 00019 00020 ACE_END_VERSIONED_NAMESPACE_DECL