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

Unified Diff: src/api.cc

Issue 1217893012: Remove deprecated v8::Object::TurnOnAccessCheck() from the V8 API. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Deoptimizer::DeoptimizeGlobalObject() removed Created 5 years, 6 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
« no previous file with comments | « include/v8.h ('k') | src/deoptimizer.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/api.cc
diff --git a/src/api.cc b/src/api.cc
index 49aeddbb1ebce44fbc389d2ef19fa2fc797e2cc2..62df2cae51ed70fa28cb38776cb248449a412dfc 100644
--- a/src/api.cc
+++ b/src/api.cc
@@ -1426,9 +1426,7 @@ void ObjectTemplate::MarkAsUndetectable() {
void ObjectTemplate::SetAccessCheckCallbacks(
NamedSecurityCallback named_callback,
- IndexedSecurityCallback indexed_callback,
- Handle<Value> data,
- bool turned_on_by_default) {
+ IndexedSecurityCallback indexed_callback, Handle<Value> data) {
i::Isolate* isolate = Utils::OpenHandle(this)->GetIsolate();
ENTER_V8(isolate);
i::HandleScope scope(isolate);
@@ -1449,7 +1447,7 @@ void ObjectTemplate::SetAccessCheckCallbacks(
info->set_data(*Utils::OpenHandle(*data));
cons->set_access_check_info(*info);
- cons->set_needs_access_check(turned_on_by_default);
+ cons->set_needs_access_check(true);
}
@@ -4262,26 +4260,6 @@ Maybe<PropertyAttribute> v8::Object::GetRealNamedPropertyAttributes(
}
-// Turns on access checks by copying the map and setting the check flag.
-// Because the object gets a new map, existing inline cache caching
-// the old map of this object will fail.
-void v8::Object::TurnOnAccessCheck() {
- i::Isolate* isolate = Utils::OpenHandle(this)->GetIsolate();
- ENTER_V8(isolate);
- i::HandleScope scope(isolate);
- i::Handle<i::JSObject> obj = Utils::OpenHandle(this);
-
- // When turning on access checks for a global object deoptimize all functions
- // as optimized code does not always handle access checks.
- i::Deoptimizer::DeoptimizeGlobalObject(*obj);
-
- i::Handle<i::Map> new_map =
- i::Map::Copy(i::Handle<i::Map>(obj->map()), "APITurnOnAccessCheck");
- new_map->set_is_access_check_needed(true);
- i::JSObject::MigrateToMap(obj, new_map);
-}
-
-
Local<v8::Object> v8::Object::Clone() {
auto self = Utils::OpenHandle(this);
auto isolate = self->GetIsolate();
« no previous file with comments | « include/v8.h ('k') | src/deoptimizer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698