summaryrefslogtreecommitdiffstats
path: root/base/strings
diff options
context:
space:
mode:
authorpalmer <palmer@chromium.org>2015-05-15 17:53:03 -0700
committerCommit bot <commit-bot@chromium.org>2015-05-16 00:53:51 +0000
commitf39e5aff5aae8451a7ef190a2fc822bf80c4e30d (patch)
tree4e9c638513f026c47a3836e77acd5b1582162561 /base/strings
parent68208a4cb9def359c3054f0769853f31602968bf (diff)
downloadchromium_src-f39e5aff5aae8451a7ef190a2fc822bf80c4e30d.zip
chromium_src-f39e5aff5aae8451a7ef190a2fc822bf80c4e30d.tar.gz
chromium_src-f39e5aff5aae8451a7ef190a2fc822bf80c4e30d.tar.bz2
Create net::FormatOriginForDisplay helper function.
net::FormatOriginForDisplay provides a canonical, concise, human-friendly display for origins. It supports callers in any higher-layer module. Based heavily on earlier work by dewittj and felt. Thanks! BUG=402698 TBR=thakis,brettw Review URL: https://codereview.chromium.org/1133943002 Cr-Commit-Position: refs/heads/master@{#330254}
Diffstat (limited to 'base/strings')
-rw-r--r--base/strings/utf_string_conversions.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/base/strings/utf_string_conversions.h b/base/strings/utf_string_conversions.h
index 06a3bc6..0d2e233 100644
--- a/base/strings/utf_string_conversions.h
+++ b/base/strings/utf_string_conversions.h
@@ -15,10 +15,10 @@ namespace base {
// These convert between UTF-8, -16, and -32 strings. They are potentially slow,
// so avoid unnecessary conversions. The low-level versions return a boolean
-// indicating whether the conversion was 100% valid. In this case, it will still
-// do the best it can and put the result in the output buffer. The versions that
-// return strings ignore this error and just return the best conversion
-// possible.
+// indicating whether the conversion was 100% valid. In case the conversion is
+// not 100% valid, these functions will still do the best they can and put the
+// result in the output buffer. The versions that return strings ignore this
+// error and just return the best conversion possible.
BASE_EXPORT bool WideToUTF8(const wchar_t* src, size_t src_len,
std::string* output);
BASE_EXPORT std::string WideToUTF8(const std::wstring& wide);
@@ -39,7 +39,7 @@ BASE_EXPORT bool UTF16ToUTF8(const char16* src, size_t src_len,
std::string* output);
BASE_EXPORT std::string UTF16ToUTF8(const string16& utf16);
-// This converts an ASCII string, typically a hardcoded constant, to a UTF16
+// This converts an ASCII string, typically a hardcoded constant, to a UTF-16
// string.
BASE_EXPORT string16 ASCIIToUTF16(const StringPiece& ascii);