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

Unified Diff: src/runtime.cc

Issue 258243003: Remove old-style accessor support from runtime. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Address comment Created 6 years, 8 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 | « src/property.h ('k') | src/serialize.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/runtime.cc
diff --git a/src/runtime.cc b/src/runtime.cc
index 2a536acd034342bdfd758c6021fb1ae82a8dca0c..dc6708f617a0e6d11405b8641365c5253cc3d477 100644
--- a/src/runtime.cc
+++ b/src/runtime.cc
@@ -1896,6 +1896,7 @@ RUNTIME_FUNCTION(Runtime_IsInPrototypeChain) {
static bool CheckAccessException(Object* callback,
v8::AccessType access_type) {
DisallowHeapAllocation no_gc;
+ ASSERT(!callback->IsForeign());
if (callback->IsAccessorInfo()) {
AccessorInfo* info = AccessorInfo::cast(callback);
return
@@ -5245,7 +5246,8 @@ RUNTIME_FUNCTION(Runtime_DefineOrRedefineDataProperty) {
// setter to update the value instead.
// TODO(mstarzinger): So far this only works if property attributes don't
// change, this should be fixed once we cleanup the underlying code.
- if ((callback->IsForeign() || callback->IsAccessorInfo()) &&
+ ASSERT(!callback->IsForeign());
+ if (callback->IsAccessorInfo() &&
lookup.GetAttributes() == attr) {
Handle<Object> result_object;
ASSIGN_RETURN_FAILURE_ON_EXCEPTION(
@@ -10812,7 +10814,8 @@ static Handle<Object> DebugLookupResultValue(Isolate* isolate,
return handle(result->GetConstant(), isolate);
case CALLBACKS: {
Handle<Object> structure(result->GetCallbackObject(), isolate);
- if (structure->IsForeign() || structure->IsAccessorInfo()) {
+ ASSERT(!structure->IsForeign());
+ if (structure->IsAccessorInfo()) {
MaybeHandle<Object> obj = JSObject::GetPropertyWithCallback(
handle(result->holder(), isolate), receiver, structure, name);
if (!obj.ToHandle(&value)) {
« no previous file with comments | « src/property.h ('k') | src/serialize.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698