node/test
isaacs 3c5ea410ca vm: Copy missing properties from context
This addresses a current shortcoming of the V8 SetNamedPropertyHandler
function.

It does not provide a way to intercept Object.defineProperty(..) calls.
As a result, these properties are not copied onto the contextified
sandbox when a new global property is added via either a function
declaration or a Object.defineProperty(global, ...) call.

Note that any function declarations or Object.defineProperty() globals
that are created asynchronously (in a setTimeout, callback, etc.) will
happen AFTER the call to copy properties, and thus not be caught.

The way to properly fix this is to add some sort of a
Object::SetNamedDefinePropertyHandler() function that takes a callback,
which receives the property name and property descriptor as arguments.

Luckily, such situations are rare, and asynchronously-added globals
weren't supported by Node's VM module until 0.12 anyway.  But, this
should be fixed properly in V8, and this copy function should be removed
once there is a better way.

Fix #6416
2013-10-28 08:43:43 -07:00
..
addons test: modify async native test.js to test for #4820 2013-02-21 13:14:07 -08:00
disabled fixes #6031 spelling errors 2013-08-19 16:42:16 -07:00
fixtures crypto: add SPKAC support 2013-10-16 09:43:19 -07:00
gc test: fix up weakref.cc after v8 api change 2013-10-23 09:17:32 -07:00
internet dns: set hostname property on error object 2013-10-16 21:56:16 +02:00
message vm: update API to use options argument 2013-08-28 22:27:24 -07:00
pummel Merge remote-tracking branch 'upstream/v0.10' 2013-10-25 11:26:05 -07:00
simple vm: Copy missing properties from context 2013-10-28 08:43:43 -07:00
common.js src: update after v8 api changes 2013-10-23 09:17:31 -07:00