Index: core/fxcrt/include/fx_string.h |
diff --git a/core/fxcrt/include/fx_string.h b/core/fxcrt/include/fx_string.h |
index 5e3cb45fba3b0c16fef2f12517b48574a8a1ddb3..38328dabdeffba31e6f350953ce5ba2b92d61612 100644 |
--- a/core/fxcrt/include/fx_string.h |
+++ b/core/fxcrt/include/fx_string.h |
@@ -167,14 +167,14 @@ class CFX_ByteString { |
static CFX_ByteString FromUnicode(const CFX_WideString& str); |
// Explicit conversion to C-style string. |
- // Note: |this| must outlive the use of the result. |
+ // Note: Any subsequent modification of |this| will invalidate the result. |
const FX_CHAR* c_str() const { return m_pData ? m_pData->m_String : ""; } |
// Implicit conversion to C-style string -- deprecated. |
operator const FX_CHAR*() const { return m_pData ? m_pData->m_String : ""; } |
// Explicit conversion to uint8_t*. |
- // Note: |this| must outlive the use of the result. |
+ // Note: Any subsequent modification of |this| will invalidate the result. |
const uint8_t* raw_str() const { |
return m_pData ? reinterpret_cast<const uint8_t*>(m_pData->m_String) |
: nullptr; |
@@ -187,7 +187,7 @@ class CFX_ByteString { |
} |
// Explicit conversion to CFX_ByteStringC. |
- // Note: |this| must outlive the use of the result. |
+ // Note: Any subsequent modification of |this| will invalidate the result. |
CFX_ByteStringC AsStringC() const { |
return CFX_ByteStringC(raw_str(), GetLength()); |
} |
@@ -503,15 +503,15 @@ class CFX_WideString { |
static FX_STRSIZE WStringLength(const unsigned short* str); |
// Explicit conversion to C-style wide string. |
- // Note: |this| must outlive the use of the result. |
+ // Note: Any subsequent modification of |this| will invalidate the result. |
const FX_WCHAR* c_str() const { return m_pData ? m_pData->m_String : L""; } |
// Implicit conversion to C-style wide string -- deprecated. |
- // Note: |this| must outlive the use of the result. |
+ // Note: Any subsequent modification of |this| will invalidate the result. |
operator const FX_WCHAR*() const { return m_pData ? m_pData->m_String : L""; } |
// Explicit conversion to CFX_WideStringC. |
- // Note: |this| must outlive the use of the result. |
+ // Note: Any subsequent modification of |this| will invalidate the result. |
CFX_WideStringC AsStringC() const { |
return CFX_WideStringC(c_str(), GetLength()); |
} |