summaryrefslogtreecommitdiff
path: root/ACE/ace/String_Base_Const.cpp
diff options
context:
space:
mode:
authorWilliam R. Otte <wotte@dre.vanderbilt.edu>2008-03-04 14:51:23 +0000
committerWilliam R. Otte <wotte@dre.vanderbilt.edu>2008-03-04 14:51:23 +0000
commit99aa8c60282c7b8072eb35eb9ac815702f5bf586 (patch)
treebda96bf8c3a4c2875a083d7b16720533c8ffeaf4 /ACE/ace/String_Base_Const.cpp
parentc4078c377d74290ebe4e66da0b4975da91732376 (diff)
downloadATCD-99aa8c60282c7b8072eb35eb9ac815702f5bf586.tar.gz
undoing accidental deletion
Diffstat (limited to 'ACE/ace/String_Base_Const.cpp')
-rw-r--r--ACE/ace/String_Base_Const.cpp20
1 files changed, 20 insertions, 0 deletions
diff --git a/ACE/ace/String_Base_Const.cpp b/ACE/ace/String_Base_Const.cpp
new file mode 100644
index 00000000000..7e431a7cb8a
--- /dev/null
+++ b/ACE/ace/String_Base_Const.cpp
@@ -0,0 +1,20 @@
+// $Id$
+
+#include "ace/String_Base_Const.h"
+#include "ace/Numeric_Limits.h"
+
+ACE_BEGIN_VERSIONED_NAMESPACE_DECL
+
+ACE_String_Base_Const::size_type const ACE_String_Base_Const::npos =
+#if defined (AIX) //&& (defined (__xlC__) || defined (__IBMCPP__))
+ // Under some mixed shared/static linking conditions, this constant
+ // will not be initialized at run-time if the
+ // std::numeric_limits<>::max() trait is used on AIX/XLC++.
+ // Workaround that problem by making it easier for the compiler to
+ // realize it can set the constant at compile-time.
+ static_cast<ACE_String_Base_Const::size_type> (-1);
+#else
+ ACE_Numeric_Limits<ACE_String_Base_Const::size_type>::max ();
+#endif /* AIX */
+
+ACE_END_VERSIONED_NAMESPACE_DECL