On 2015/03/26 14:08:46, caitp wrote:
https://codereview.chromium.org/1027283004/diff/370001/src/factory.cc
File src/factory.cc (right):


https://codereview.chromium.org/1027283004/diff/370001/src/factory.cc#newcode1284
src/factory.cc:1284: // In strict mode, readonly strict map is only available
during bootstrap
On 2015/03/26 13:59:14, arv wrote:
> I still find this confusing :-)
>
> strict map with readonly prototype is what we use for classes for example.

That seems to happen in Runtime_DefineClass --- the constructor's "prototype"
property is explicitly set to [[Enumerable]]=false, [[Writable]]=false,
[[Configurable]]=false --- In strong mode this is probably not necessary
(strong
mode has its own constructor map variant), but in strict mode it just uses the
strict function map, which for most of the life of the engine will have a
writable prototype

That is a good point. The current class definition code does not create the
function with a readonly prototype but sets the prototype and then make that
readonly.

https://codereview.chromium.org/1027283004/

--
--
v8-dev mailing list
v8-dev@googlegroups.com
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 v8-dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to