From f653480a0ce63df3861042dbd3c6ac4eddae2ccb Mon Sep 17 00:00:00 2001 From: "yangguo@chromium.org" Date: Mon, 3 Sep 2012 15:40:00 +0000 Subject: [PATCH] Fix windows compile errors introduced by r12430. R=ulan@chromium.org BUG= Review URL: https://chromiumcodereview.appspot.com/10907049 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@12432 ce2b1a6d-e550-0410-aec6-3dcde31c8c00 --- src/api.cc | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/api.cc b/src/api.cc index c8d5a9c190..ec788556c4 100644 --- a/src/api.cc +++ b/src/api.cc @@ -4943,15 +4943,17 @@ Local v8::String::NewExternal(ExternalLatin1StringResource* resource, ENTER_V8(isolate); ASSERT((encoding & kStringEncodingMask) == LATIN1_ENCODING); CHECK(resource && resource->data()); - bool ascii_hint = (encoding & kAsciiHintMask); + int ascii_hint = (encoding & kAsciiHintMask); i::Handle result; if (ascii_hint == ASCII_HINT || (ascii_hint != NOT_ASCII_HINT && - i::String::IsAscii(resource->data(), resource->length()))) { + i::String::IsAscii(resource->data(), + static_cast(resource->length())))) { // Assert that the ascii hint is correct. ASSERT(ascii_hint != ASCII_HINT || - i::String::IsAscii(resource->data(), resource->length())); + i::String::IsAscii(resource->data(), + static_cast(resource->length()))); result = NewExternalAsciiStringHandle(isolate, resource); isolate->heap()->external_string_table()->AddString(*result); } else {