mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-20 16:55:40 +00:00
Bug 987111 - Proxy::set should create enumerable properties. r=efaust
Properties are supposed to be enumerable by default. It's unfortunate that the default is reversed in SpiderMonkey.
This commit is contained in:
parent
16aa8bb904
commit
dd53b3d419
@ -2587,6 +2587,7 @@ Proxy::set(JSContext *cx, HandleObject proxy, HandleObject receiver, HandleId id
|
||||
// that we're going to shadow. Make a property descriptor and define it.
|
||||
Rooted<PropertyDescriptor> newDesc(cx);
|
||||
newDesc.value().set(vp);
|
||||
newDesc.setAttributes(JSPROP_ENUMERATE);
|
||||
return handler->defineProperty(cx, receiver, id, &newDesc);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user