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

Unified Diff: src/api.cc

Issue 6576024: (early draft) Strict mode - throw exception on assignment to read only property. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Assign to read only property in strict mode. Created 9 years, 10 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 | « no previous file | src/arm/codegen-arm.cc » ('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 d718c8875b5973e11a6cc6151f96bb773f4baa55..a2d0827dc7bf3ac6d54c166fd39e14f76a3b1042 100644
--- a/src/api.cc
+++ b/src/api.cc
@@ -2286,7 +2286,8 @@ bool v8::Object::Set(v8::Handle<Value> key, v8::Handle<Value> value,
self,
key_obj,
value_obj,
- static_cast<PropertyAttributes>(attribs));
+ static_cast<PropertyAttributes>(attribs),
+ i::kNonStrictMode); // TODO(mmaly): v8::Object::Set API. Needs strict?
has_pending_exception = obj.is_null();
EXCEPTION_BAILOUT_CHECK(false);
return true;
@@ -2711,7 +2712,8 @@ bool v8::Object::SetHiddenValue(v8::Handle<v8::String> key,
hidden_props,
key_obj,
value_obj,
- static_cast<PropertyAttributes>(None));
+ static_cast<PropertyAttributes>(None),
+ i::kNonStrictMode); // v8::Object::SetHiddenValue doesn't need strict.
has_pending_exception = obj.is_null();
EXCEPTION_BAILOUT_CHECK(false);
return true;
« no previous file with comments | « no previous file | src/arm/codegen-arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698