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

[runtime] Remove redundant empty-string check in lookup iterator

Change-Id: I2d5b54c88bece3e22c4ae25d7fba094647f64f52
Reviewed-on: https://chromium-review.googlesource.com/c/1487051Reviewed-by: 's avatarMaya Lekova <mslekova@chromium.org>
Commit-Queue: Georg Neis <neis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59850}
parent 73d16d9a
......@@ -1082,11 +1082,8 @@ JSReceiver LookupIterator::NextHolder(Map map) {
LookupIterator::State LookupIterator::NotFound(JSReceiver const holder) const {
DCHECK(!IsElement());
if (!holder->IsJSTypedArray() || !name_->IsString()) return NOT_FOUND;
Handle<String> name_string = Handle<String>::cast(name_);
if (name_string->length() == 0) return NOT_FOUND;
return IsSpecialIndex(*name_string) ? INTEGER_INDEXED_EXOTIC : NOT_FOUND;
return IsSpecialIndex(String::cast(*name_)) ? INTEGER_INDEXED_EXOTIC
: NOT_FOUND;
}
namespace {
......
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