Reviewers: mvstanton,
Description:
Fix potential assertion failure in ConvertCase.
IsOneByteRepresentationUnderneath requires the string to be flat, which is
not
guaranteed in this case. Using IsOneByteRepresentation is sufficient here.
[email protected]
BUG=
Please review this at https://codereview.chromium.org/62493007/
SVN Base: https://v8.googlecode.com/svn/branches/bleeding_edge
Affected files (+1, -1 lines):
M src/runtime.cc
Index: src/runtime.cc
diff --git a/src/runtime.cc b/src/runtime.cc
index
7da24c3826937d3a8670fc05f16132688c83fed5..bf4fa4e57ca83e5274c49398a1d662255016f4b4
100644
--- a/src/runtime.cc
+++ b/src/runtime.cc
@@ -6444,7 +6444,7 @@ MUST_USE_RESULT static MaybeObject* ConvertCase(
}
}
- String::Encoding result_encoding = s->IsOneByteRepresentationUnderneath()
+ String::Encoding result_encoding = s->IsOneByteRepresentation()
? String::ONE_BYTE_ENCODING : String::TWO_BYTE_ENCODING;
Object* answer;
{ MaybeObject* maybe_answer = ConvertCaseHelper(
--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.