Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(689)

Unified Diff: src/objects.cc

Issue 2131383002: [builtins] take slow path in IsConcatSpreadable if proxy in prototype (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Refactor Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: src/objects.cc
diff --git a/src/objects.cc b/src/objects.cc
index b2159fade0ed4683b7f543b09757755b1cb37fda..8fe8fbc2c29173ba890abea1723820a4eeecfd93 100644
--- a/src/objects.cc
+++ b/src/objects.cc
@@ -18943,5 +18943,14 @@ AccessCheckInfo* AccessCheckInfo::Get(Isolate* isolate,
return AccessCheckInfo::cast(data_obj);
}
+bool JSReceiver::HasProxyInPrototype(Isolate* isolate) {
+ for (PrototypeIterator iter(isolate, this, kStartAtReceiver,
+ PrototypeIterator::END_AT_NULL);
+ !iter.IsAtEnd(); iter.AdvanceIgnoringProxies()) {
+ if (iter.GetCurrent<Object>()->IsJSProxy()) return true;
+ }
+ return false;
+}
+
} // namespace internal
} // namespace v8

Powered by Google App Engine
This is Rietveld 408576698