Index: core/include/fxcrt/fx_string.h |
diff --git a/core/include/fxcrt/fx_string.h b/core/include/fxcrt/fx_string.h |
index df7dd0c76241e359af3e367c400d759a9da9c463..9061c5d90e37b1ee412e0780c5e3edb6e37d3f67 100644 |
--- a/core/include/fxcrt/fx_string.h |
+++ b/core/include/fxcrt/fx_string.h |
@@ -7,6 +7,8 @@ |
#ifndef _FX_STRING_H_ |
#define _FX_STRING_H_ |
+#include <algorithm> |
+ |
#include "fx_memory.h" |
class CFX_ByteStringC; |
@@ -702,6 +704,11 @@ public: |
const CFX_WideString& operator += (const CFX_WideStringC& str); |
+ bool operator< (const CFX_WideString& str) const { |
+ int result = wmemcmp(c_str(), str.c_str(), std::min(GetLength(), str.GetLength())); |
+ return result < 0 || (result == 0 && GetLength() < str.GetLength()); |
+ } |
+ |
FX_WCHAR GetAt(FX_STRSIZE nIndex) const |
{ |
return m_pData ? m_pData->m_String[nIndex] : 0; |