Commit d5feb5c0 authored by Georg Neis's avatar Georg Neis Committed by Commit Bot

[runtime] Weaken a DCHECK

It can happen that the {value} handle initially (when we stored its
contents into the property cell) contained a ThinString but was
subsequently patched by the scavenger to hold the InternalizedString
directly.

Bug: v8:11675
Change-Id: Ia3e5fed5bd28313b6fd2031eee0658ac4136a7ca
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2843350Reviewed-by: 's avatarUlan Degenbaev <ulan@chromium.org>
Commit-Queue: Georg Neis <neis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#74083}
parent a8a8e6b7
...@@ -1031,7 +1031,9 @@ void LookupIterator::WriteDataValue(Handle<Object> value, ...@@ -1031,7 +1031,9 @@ void LookupIterator::WriteDataValue(Handle<Object> value,
GlobalDictionary dictionary = GlobalDictionary dictionary =
JSGlobalObject::cast(*holder).global_dictionary(isolate_, kAcquireLoad); JSGlobalObject::cast(*holder).global_dictionary(isolate_, kAcquireLoad);
PropertyCell cell = dictionary.CellAt(isolate_, dictionary_entry()); PropertyCell cell = dictionary.CellAt(isolate_, dictionary_entry());
DCHECK_EQ(cell.value(), *value); DCHECK(cell.value() == *value ||
cell.value().IsString() && value->IsString() &&
String::cast(cell.value()).Equals(String::cast(*value)));
#endif // DEBUG #endif // DEBUG
} else { } else {
DCHECK_IMPLIES(holder->IsJSProxy(isolate_), name()->IsPrivate(isolate_)); DCHECK_IMPLIES(holder->IsJSProxy(isolate_), name()->IsPrivate(isolate_));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment