diff options
author | Steven R. Loomis <srloomis@us.ibm.com> | 2018-02-08 03:42:21 +0300 |
---|---|---|
committer | Steven R. Loomis <srloomis@us.ibm.com> | 2018-02-10 05:09:08 +0300 |
commit | b8f47b27571f8d763f811f017be3fb37d466c4fc (patch) | |
tree | 4101d07d6dd3b2f13a9c9d4423d8a80084214f8c /src/inspector_io.cc | |
parent | 9b4aa78f720284b5ad43850bbef90400ca010845 (diff) |
src: add "icu::" prefix before ICU symbols
In ICU 61.x, icu4c will no longer put its declarations in the global namespace.
Everything will be in the "icu::" namespace (or icu_60:: in the linker).
Prepare for this.
https://ssl.icu-project.org/trac/ticket/13460
Diffstat (limited to 'src/inspector_io.cc')
-rw-r--r-- | src/inspector_io.cc | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/inspector_io.cc b/src/inspector_io.cc index 9af4458c6b2..01ddc296b08 100644 --- a/src/inspector_io.cc +++ b/src/inspector_io.cc @@ -74,11 +74,11 @@ std::string StringViewToUtf8(const StringView& view) { size_t result_length = view.length() * sizeof(*source); std::string result(result_length, '\0'); - UnicodeString utf16(unicodeSource, view.length()); + icu::UnicodeString utf16(unicodeSource, view.length()); // ICU components for std::string compatibility are not enabled in build... bool done = false; while (!done) { - CheckedArrayByteSink sink(&result[0], result_length); + icu::CheckedArrayByteSink sink(&result[0], result_length); utf16.toUTF8(sink); result_length = sink.NumberOfBytesAppended(); result.resize(result_length); @@ -111,8 +111,9 @@ void ReleasePairOnAsyncClose(uv_handle_t* async) { } // namespace std::unique_ptr<StringBuffer> Utf8ToStringView(const std::string& message) { - UnicodeString utf16 = - UnicodeString::fromUTF8(StringPiece(message.data(), message.length())); + icu::UnicodeString utf16 = + icu::UnicodeString::fromUTF8(icu::StringPiece(message.data(), + message.length())); StringView view(reinterpret_cast<const uint16_t*>(utf16.getBuffer()), utf16.length()); return StringBuffer::create(view); |