mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1148750, part 5 - CompletePropertyDescriptor upgrade. r=efaust.
This commit is contained in:
parent
3dfe729a4a
commit
23ec0fc12f
@ -809,9 +809,9 @@ js::CheckPropertyDescriptorAccessors(JSContext* cx, Handle<PropertyDescriptor> d
|
||||
void
|
||||
js::CompletePropertyDescriptor(MutableHandle<PropertyDescriptor> desc)
|
||||
{
|
||||
desc.assertValid();
|
||||
|
||||
if (desc.isGenericDescriptor() || desc.isDataDescriptor()) {
|
||||
if (!desc.hasValue())
|
||||
desc.value().setUndefined();
|
||||
if (!desc.hasWritable())
|
||||
desc.attributesRef() |= JSPROP_READONLY;
|
||||
desc.attributesRef() &= ~(JSPROP_IGNORE_READONLY | JSPROP_IGNORE_VALUE);
|
||||
@ -822,11 +822,11 @@ js::CompletePropertyDescriptor(MutableHandle<PropertyDescriptor> desc)
|
||||
desc.setSetterObject(nullptr);
|
||||
desc.attributesRef() |= JSPROP_GETTER | JSPROP_SETTER | JSPROP_SHARED;
|
||||
}
|
||||
if (!desc.hasEnumerable())
|
||||
desc.attributesRef() &= ~JSPROP_ENUMERATE;
|
||||
if (!desc.hasConfigurable())
|
||||
desc.attributesRef() |= JSPROP_PERMANENT;
|
||||
desc.attributesRef() &= ~(JSPROP_IGNORE_PERMANENT | JSPROP_IGNORE_ENUMERATE);
|
||||
|
||||
desc.assertComplete();
|
||||
}
|
||||
|
||||
bool
|
||||
|
Loading…
Reference in New Issue
Block a user