Changed JSObject::DefineGetterSetter to also set the right attributes
when an existing accessor is redefined (a configurable accessor can potentially be redefined as a non-configurable (i.e., DONT_DELETE)). Review URL: http://codereview.chromium.org/556040 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3719 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
parent
7985bf73c8
commit
80d71c6406
@ -2839,7 +2839,11 @@ Object* JSObject::DefineGetterSetter(String* name,
|
||||
if (result.IsReadOnly()) return Heap::undefined_value();
|
||||
if (result.type() == CALLBACKS) {
|
||||
Object* obj = result.GetCallbackObject();
|
||||
if (obj->IsFixedArray()) return obj;
|
||||
if (obj->IsFixedArray()) {
|
||||
PropertyDetails details = PropertyDetails(attributes, CALLBACKS);
|
||||
SetNormalizedProperty(name, obj, details);
|
||||
return obj;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user