Comment #3 on issue 4146 by [email protected]: Passing a frozen regexp as the first argument to str.replace does not throw
https://code.google.com/p/v8/issues/detail?id=4146

Setting the property to the same value should not throw an exception

It totally should.  Simple testcase:

  "use strict";
  var x = { y : 0 };
  Object.freeze(x);
  x.y = 0;

V8 throws on that testcase. The reason it should throw is described in https://bugzilla.mozilla.org/show_bug.cgi?id=1168257#c6 -- [[Set]] will bail out before ever calling [[DefineOwnProperty]] if setting an existing readonly property.

So SpiderMonkey is in fact doing the right thing here. Now how do I reopen bugs in this bug system? ;)

--
You received this message because this project is configured to send all issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings

--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
--- You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to