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

Side by Side Diff: src/unicode.cc

Issue 2481013010: [parser, serializer] Fix more -Wsign-compare warnings. (Closed)
Patch Set: Created 4 years, 1 month 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/parsing/scanner-character-streams.cc ('k') | src/value-serializer.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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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 // This file was generated at 2014-10-08 15:25:47.940335 5 // This file was generated at 2014-10-08 15:25:47.940335
6 6
7 #include "src/unicode.h" 7 #include "src/unicode.h"
8 #include "src/unicode-inl.h" 8 #include "src/unicode-inl.h"
9 #include <stdio.h> 9 #include <stdio.h>
10 #include <stdlib.h> 10 #include <stdlib.h>
(...skipping 328 matching lines...) Expand 10 before | Expand all | Expand 10 after
339 uchar previous = *buffer; 339 uchar previous = *buffer;
340 *buffer = 0; 340 *buffer = 0;
341 uchar t = ValueOfIncremental(previous, buffer); 341 uchar t = ValueOfIncremental(previous, buffer);
342 if (t == kIncomplete) { 342 if (t == kIncomplete) {
343 // If we have an incomplete character, process both the previous and the 343 // If we have an incomplete character, process both the previous and the
344 // next byte at once. 344 // next byte at once.
345 return ValueOfIncremental(next, buffer); 345 return ValueOfIncremental(next, buffer);
346 } else { 346 } else {
347 // Otherwise, process the previous byte and save the next byte for next 347 // Otherwise, process the previous byte and save the next byte for next
348 // time. 348 // time.
349 DCHECK_EQ(0, *buffer); 349 DCHECK_EQ(0u, *buffer);
350 *buffer = next; 350 *buffer = next;
351 return t; 351 return t;
352 } 352 }
353 } else if (IsContinuationCharacter(next)) { 353 } else if (IsContinuationCharacter(next)) {
354 // We're inside of a character, as described by buffer. 354 // We're inside of a character, as described by buffer.
355 355
356 // How many bytes (excluding this one) do we still expect? 356 // How many bytes (excluding this one) do we still expect?
357 uint8_t count = (*buffer >> 24) - 1; 357 uint8_t count = (*buffer >> 24) - 1;
358 // Update the value. 358 // Update the value.
359 uint32_t value = ((*buffer & 0xffffff) << 6) | (next & 0x3F); 359 uint32_t value = ((*buffer & 0xffffff) << 6) | (next & 0x3F);
(...skipping 3166 matching lines...) Expand 10 before | Expand all | Expand 10 after
3526 sizeof(MultiCharacterSpecialCase<1>) // NOLINT 3526 sizeof(MultiCharacterSpecialCase<1>) // NOLINT
3527 + 3527 +
3528 kCanonicalizationRangeMultiStrings1Size * 3528 kCanonicalizationRangeMultiStrings1Size *
3529 sizeof(MultiCharacterSpecialCase<1>) // NOLINT 3529 sizeof(MultiCharacterSpecialCase<1>) // NOLINT
3530 + 3530 +
3531 kCanonicalizationRangeMultiStrings7Size * 3531 kCanonicalizationRangeMultiStrings7Size *
3532 sizeof(MultiCharacterSpecialCase<1>); // NOLINT 3532 sizeof(MultiCharacterSpecialCase<1>); // NOLINT
3533 } 3533 }
3534 3534
3535 } // namespace unibrow 3535 } // namespace unibrow
OLDNEW
« no previous file with comments | « src/parsing/scanner-character-streams.cc ('k') | src/value-serializer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698