summaryrefslogtreecommitdiffstats
path: root/base/strings
diff options
context:
space:
mode:
authorpkasting@chromium.org <pkasting@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-03-18 18:51:49 +0000
committerpkasting@chromium.org <pkasting@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-03-18 18:51:49 +0000
commit89d1a8b163dc905efeea6d391f4d02deafccf59c (patch)
tree833cb573bf1898ff4509a167058cc66ec880844a /base/strings
parent6332c75e574adbc24c3462a0f6405bcd278a2cc3 (diff)
downloadchromium_src-89d1a8b163dc905efeea6d391f4d02deafccf59c.zip
chromium_src-89d1a8b163dc905efeea6d391f4d02deafccf59c.tar.gz
chromium_src-89d1a8b163dc905efeea6d391f4d02deafccf59c.tar.bz2
Remove two Unicode characters that are not white space per
http://www.unicode.org/Public/7.0.0/ucd/PropList-7.0.0d29.txt. This also gives all constants their official Unicode names. BUG=60231 TEST=Copy string from bug comment 0, but paste into omnibox instead of find box. Ensure there is no space in the pasted string. R=brettw@chromium.org Review URL: https://codereview.chromium.org/198853004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@257704 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/strings')
-rw-r--r--base/strings/string_util_constants.cc64
1 files changed, 31 insertions, 33 deletions
diff --git a/base/strings/string_util_constants.cc b/base/strings/string_util_constants.cc
index 2a28a2b..146e5fd 100644
--- a/base/strings/string_util_constants.cc
+++ b/base/strings/string_util_constants.cc
@@ -7,33 +7,31 @@
namespace base {
#define WHITESPACE_UNICODE \
- 0x0009, /* <control-0009> to <control-000D> */ \
- 0x000A, \
- 0x000B, \
- 0x000C, \
- 0x000D, \
- 0x0020, /* Space */ \
- 0x0085, /* <control-0085> */ \
- 0x00A0, /* No-Break Space */ \
- 0x1680, /* Ogham Space Mark */ \
- 0x180E, /* Mongolian Vowel Separator */ \
- 0x2000, /* En Quad to Hair Space */ \
- 0x2001, \
- 0x2002, \
- 0x2003, \
- 0x2004, \
- 0x2005, \
- 0x2006, \
- 0x2007, \
- 0x2008, \
- 0x2009, \
- 0x200A, \
- 0x200C, /* Zero Width Non-Joiner */ \
- 0x2028, /* Line Separator */ \
- 0x2029, /* Paragraph Separator */ \
- 0x202F, /* Narrow No-Break Space */ \
- 0x205F, /* Medium Mathematical Space */ \
- 0x3000, /* Ideographic Space */ \
+ 0x0009, /* CHARACTER TABULATION */ \
+ 0x000A, /* LINE FEED (LF) */ \
+ 0x000B, /* LINE TABULATION */ \
+ 0x000C, /* FORM FEED (FF) */ \
+ 0x000D, /* CARRIAGE RETURN (CR) */ \
+ 0x0020, /* SPACE */ \
+ 0x0085, /* NEXT LINE (NEL) */ \
+ 0x00A0, /* NO-BREAK SPACE */ \
+ 0x1680, /* OGHAM SPACE MARK */ \
+ 0x2000, /* EN QUAD */ \
+ 0x2001, /* EM QUAD */ \
+ 0x2002, /* EN SPACE */ \
+ 0x2003, /* EM SPACE */ \
+ 0x2004, /* THREE-PER-EM SPACE */ \
+ 0x2005, /* FOUR-PER-EM SPACE */ \
+ 0x2006, /* SIX-PER-EM SPACE */ \
+ 0x2007, /* FIGURE SPACE */ \
+ 0x2008, /* PUNCTUATION SPACE */ \
+ 0x2009, /* THIN SPACE */ \
+ 0x200A, /* HAIR SPACE */ \
+ 0x2028, /* LINE SEPARATOR */ \
+ 0x2029, /* PARAGRAPH SEPARATOR */ \
+ 0x202F, /* NARROW NO-BREAK SPACE */ \
+ 0x205F, /* MEDIUM MATHEMATICAL SPACE */ \
+ 0x3000, /* IDEOGRAPHIC SPACE */ \
0
const wchar_t kWhitespaceWide[] = {
@@ -45,12 +43,12 @@ const char16 kWhitespaceUTF16[] = {
};
const char kWhitespaceASCII[] = {
- 0x09, // <control-0009> to <control-000D>
- 0x0A,
- 0x0B,
- 0x0C,
- 0x0D,
- 0x20, // Space
+ 0x09, // CHARACTER TABULATION
+ 0x0A, // LINE FEED (LF)
+ 0x0B, // LINE TABULATION
+ 0x0C, // FORM FEED (FF)
+ 0x0D, // CARRIAGE RETURN (CR)
+ 0x20, // SPACE
0
};