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

Side by Side Diff: src/unicode.h

Issue 2331303002: Use ICU for ID_START and ID_CONTINUE for Unicode 9 data (Closed)
Patch Set: drop an unnecessary todo Created 3 years, 6 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 unified diff | Download patch
« no previous file with comments | « src/char-predicates.cc ('k') | src/unicode.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_UNICODE_H_ 5 #ifndef V8_UNICODE_H_
6 #define V8_UNICODE_H_ 6 #define V8_UNICODE_H_
7 7
8 #include <sys/types.h> 8 #include <sys/types.h>
9 #include "src/globals.h" 9 #include "src/globals.h"
10 #include "src/utils.h" 10 #include "src/utils.h"
(...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after
173 // This method checks for: 173 // This method checks for:
174 // - valid utf-8 endcoding (e.g. no over-long encodings), 174 // - valid utf-8 endcoding (e.g. no over-long encodings),
175 // - absence of surrogates, 175 // - absence of surrogates,
176 // - valid code point range. 176 // - valid code point range.
177 static bool ValidateEncoding(const byte* str, size_t length); 177 static bool ValidateEncoding(const byte* str, size_t length);
178 }; 178 };
179 179
180 struct Uppercase { 180 struct Uppercase {
181 static bool Is(uchar c); 181 static bool Is(uchar c);
182 }; 182 };
183 struct Lowercase {
184 static bool Is(uchar c);
185 };
186 struct Letter { 183 struct Letter {
187 static bool Is(uchar c); 184 static bool Is(uchar c);
188 }; 185 };
186 #ifndef V8_INTL_SUPPORT
189 struct V8_EXPORT_PRIVATE ID_Start { 187 struct V8_EXPORT_PRIVATE ID_Start {
190 static bool Is(uchar c); 188 static bool Is(uchar c);
191 }; 189 };
192 struct V8_EXPORT_PRIVATE ID_Continue { 190 struct V8_EXPORT_PRIVATE ID_Continue {
193 static bool Is(uchar c); 191 static bool Is(uchar c);
194 }; 192 };
195 struct V8_EXPORT_PRIVATE WhiteSpace { 193 struct V8_EXPORT_PRIVATE WhiteSpace {
196 static bool Is(uchar c); 194 static bool Is(uchar c);
197 }; 195 };
196 #endif // !V8_INTL_SUPPORT
198 struct V8_EXPORT_PRIVATE LineTerminator { 197 struct V8_EXPORT_PRIVATE LineTerminator {
199 static bool Is(uchar c); 198 static bool Is(uchar c);
200 }; 199 };
201 struct ToLowercase { 200 struct ToLowercase {
202 static const int kMaxWidth = 3; 201 static const int kMaxWidth = 3;
203 static const bool kIsToLower = true; 202 static const bool kIsToLower = true;
204 static int Convert(uchar c, 203 static int Convert(uchar c,
205 uchar n, 204 uchar n,
206 uchar* result, 205 uchar* result,
207 bool* allow_caching_ptr); 206 bool* allow_caching_ptr);
(...skipping 24 matching lines...) Expand all
232 static const int kMaxWidth = 1; 231 static const int kMaxWidth = 1;
233 static int Convert(uchar c, 232 static int Convert(uchar c,
234 uchar n, 233 uchar n,
235 uchar* result, 234 uchar* result,
236 bool* allow_caching_ptr); 235 bool* allow_caching_ptr);
237 }; 236 };
238 237
239 } // namespace unibrow 238 } // namespace unibrow
240 239
241 #endif // V8_UNICODE_H_ 240 #endif // V8_UNICODE_H_
OLDNEW
« no previous file with comments | « src/char-predicates.cc ('k') | src/unicode.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698