Changeset 27756 in webkit for trunk/JavaScriptCore


Ignore:
Timestamp:
Nov 13, 2007, 11:54:40 AM (18 years ago)
Author:
[email protected]
Message:

Windows build fix.

  • bindings/c/c_utility.cpp: (KJS::Bindings::convertUTF8ToUTF16):
  • kjs/ustring.cpp: (KJS::UString::UTF8String):
  • wtf/unicode/UTF8.cpp: (WTF::Unicode::ConvertUTF8ToUTF16):
Location:
trunk/JavaScriptCore
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/ChangeLog

    r27752 r27756  
     12007-11-13  Alexey Proskuryakov  <[email protected]>
     2
     3        Windows build fix.
     4
     5        * bindings/c/c_utility.cpp:
     6        (KJS::Bindings::convertUTF8ToUTF16):
     7        * kjs/ustring.cpp:
     8        (KJS::UString::UTF8String):
     9        * wtf/unicode/UTF8.cpp:
     10        (WTF::Unicode::ConvertUTF8ToUTF16):
     11
    1122007-11-13  Darin Adler  <[email protected]>
    213
  • trunk/JavaScriptCore/bindings/c/c_utility.cpp

    r27746 r27756  
    7272    ConversionResult result = ConvertUTF8ToUTF16(&sourcestart, sourceend, &targetstart, targetend, true);
    7373   
    74     *UTF16Length = targetstart - *UTF16Chars;
     74    *UTF16Length = targetstart - reinterpret_cast< ::UChar*>(*UTF16Chars);
    7575
    7676    // Check to see if the conversion was successful
  • trunk/JavaScriptCore/kjs/ustring.cpp

    r27750 r27756  
    12821282  // Convert to runs of 8-bit characters.
    12831283  char* p = buffer.data();
    1284   const ::UChar* d = &data()->uc;
     1284  const ::UChar* d = reinterpret_cast<const ::UChar*>(&data()->uc);
    12851285  ConversionResult result = ConvertUTF16ToUTF8(&d, d + length, &p, p + buffer.size(), strict);
    12861286  if (result != conversionOK)
  • trunk/JavaScriptCore/wtf/unicode/UTF8.cpp

    r27746 r27756  
    118118// (I.e., one byte sequence, two byte... etc.). Remember that sequencs
    119119// for *legal* UTF-8 will be 4 or fewer bytes total.
    120 static const char firstByteMark[7] = { 0x00, 0x00, 0xC0, 0xE0, 0xF0, 0xF8, 0xFC };
     120static const unsigned char firstByteMark[7] = { 0x00, 0x00, 0xC0, 0xE0, 0xF0, 0xF8, 0xFC };
    121121
    122122ConversionResult ConvertUTF16ToUTF8(
     
    240240    while (source < sourceEnd) {
    241241        UChar32 ch = 0;
    242         unsigned short extraBytesToRead = UTF8SequenceLength(*source) - 1;
     242        int extraBytesToRead = UTF8SequenceLength(*source) - 1;
    243243        if (source + extraBytesToRead >= sourceEnd) {
    244244            result = sourceExhausted;
Note: See TracChangeset for help on using the changeset viewer.