Ensure that external symbols have hash codes.

Review URL: http://codereview.chromium.org/11443

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@785 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
ager@chromium.org 2008-11-18 10:55:50 +00:00
parent 27e4365aba
commit 6e931081e3

View File

@ -2142,6 +2142,8 @@ Object* Heap::AllocateExternalSymbol(Vector<const char> string, int chars) {
// Patch the resource pointer of the result.
ExternalTwoByteString* result = ExternalTwoByteString::cast(obj);
result->set_resource(resource);
// Force hash code to be computed.
result->Hash();
ASSERT(result->IsEqualTo(string));
return result;
}