Index: src/objects.cc |
diff --git a/src/objects.cc b/src/objects.cc |
index 85a40f6be6f0a996fe9ba90cca0eda3ad96e6087..d5127f8a29f2d3ea757cdc273ca15951ea2ee2fb 100644 |
--- a/src/objects.cc |
+++ b/src/objects.cc |
@@ -2117,6 +2117,7 @@ MaybeObject* JSObject::SetPropertyViaPrototypes( |
break; |
} |
case CALLBACKS: { |
+ if (!FLAG_es5_readonly && result.IsReadOnly()) break; |
*done = true; |
return SetPropertyWithCallback(result.GetCallbackObject(), |
name, value, result.holder(), strict_mode); |
@@ -2550,7 +2551,10 @@ void JSObject::LookupRealNamedPropertyInPrototypes(String* name, |
return result->HandlerResult(JSProxy::cast(pt)); |
} |
JSObject::cast(pt)->LocalLookupRealNamedProperty(name, result); |
- if (result->IsProperty()) return; |
+ if (result->IsProperty()) { |
+ ASSERT(result->type() != INTERCEPTOR); |
Michael Starzinger
2012/06/05 16:51:14
Can we move that out of into one line doing just t
|
+ return; |
+ } |
} |
result->NotFound(); |
} |