Fix build.

This commit is contained in:
Victor Zverovich 2014-06-30 18:26:46 -07:00
parent 35866bb2c2
commit 536fedfe0f

View File

@ -518,7 +518,7 @@ class UTF8ToUTF16 {
explicit UTF8ToUTF16(StringRef s); explicit UTF8ToUTF16(StringRef s);
operator WStringRef() const { return WStringRef(&buffer_[0], size()); } operator WStringRef() const { return WStringRef(&buffer_[0], size()); }
size_t size() const { return buffer_.size() - 1; } size_t size() const { return buffer_.size() - 1; }
std::wstring() const { return std::wstring(&buffer_[0], size()); } std::wstring str() const { return std::wstring(&buffer_[0], size()); }
}; };
// A converter from UTF-16 to UTF-8. // A converter from UTF-16 to UTF-8.
@ -532,7 +532,7 @@ class UTF16ToUTF8 {
explicit UTF16ToUTF8(WStringRef s); explicit UTF16ToUTF8(WStringRef s);
operator StringRef() const { return StringRef(&buffer_[0], size()); } operator StringRef() const { return StringRef(&buffer_[0], size()); }
size_t size() const { return buffer_.size() - 1; } size_t size() const { return buffer_.size() - 1; }
std::string() const { return std::string(&buffer_[0], size()); } std::string str() const { return std::string(&buffer_[0], size()); }
// Performs conversion returning a system error code instead of // Performs conversion returning a system error code instead of
// throwing exception on error. // throwing exception on error.