Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(360)

Unified Diff: src/unicode-inl.h

Issue 11962035: Fix some latin-1 webkit units tests (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Fixed last latin-1 webkit test failure Created 7 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/unicode.h ('k') | test/cctest/test-strings.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/unicode-inl.h
diff --git a/src/unicode-inl.h b/src/unicode-inl.h
index b4e2cb52130c5ca8cb94c6ca26f403a28dd1cb56..c80c67e1af68d9803bf87a918d3b572c00b27fd1 100644
--- a/src/unicode-inl.h
+++ b/src/unicode-inl.h
@@ -79,33 +79,19 @@ template <class T, int s> int Mapping<T, s>::CalculateValue(uchar c, uchar n,
}
-bool Latin1::NonLatin1CanBeConvertedToLatin1(uint16_t c) {
+uint16_t Latin1::ConvertNonLatin1ToLatin1(uint16_t c) {
ASSERT(c > Latin1::kMaxChar);
switch (c) {
- case 0x130:
- case 0x131:
- case 0x149:
+ // This are equivalent characters in unicode.
+ case 0x39c:
+ case 0x3bc:
+ return 0xb5;
+ // This is an uppercase of a Latin-1 character
+ // outside of Latin-1.
case 0x178:
- case 0x17f:
- case 0x1f0:
- case 0x1e96:
- case 0x1e97:
- case 0x1e98:
- case 0x1e99:
- case 0x1e9a:
- case 0x1e9e:
- case 0x212a:
- case 0x212b:
- case 0xfb00:
- case 0xfb01:
- case 0xfb02:
- case 0xfb03:
- case 0xfb04:
- case 0xfb05:
- case 0xfb06:
- return true;
+ return 0xff;
}
- return false;
+ return 0;
}
« no previous file with comments | « src/unicode.h ('k') | test/cctest/test-strings.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698