Changeset 197412 in webkit for trunk/Source/JavaScriptCore/runtime/ProxyObject.cpp
- Timestamp:
- Mar 1, 2016, 1:45:16 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/runtime/ProxyObject.cpp
r197383 r197412 197 197 // FIXME: this doesn't work if 'target' is another Proxy. We don't have isExtensible implemented in a way that fits w/ Proxys. 198 198 // https://bugs.webkit.org/show_bug.cgi?id=154375 199 if (!target->isExtensible()) { 199 bool isExtensible = target->isExtensibleInline(exec); 200 if (exec->hadException()) 201 return false; 202 if (!isExtensible) { 200 203 // FIXME: Come up with a test for this error. I'm not sure how to because 201 204 // Object.seal(o) will make all fields [[Configurable]] false. … … 208 211 } 209 212 213 bool isExtensible = target->isExtensibleInline(exec); 214 if (exec->hadException()) 215 return false; 210 216 PropertyDescriptor trapResultAsDescriptor; 211 217 toPropertyDescriptor(exec, trapResult, trapResultAsDescriptor); … … 213 219 return false; 214 220 bool throwException = false; 215 bool valid = validateAndApplyPropertyDescriptor(exec, nullptr, propertyName, target->isExtensible(),221 bool valid = validateAndApplyPropertyDescriptor(exec, nullptr, propertyName, isExtensible, 216 222 trapResultAsDescriptor, isTargetPropertyDescriptorDefined, targetPropertyDescriptor, throwException); 217 223 if (!valid) { … … 289 295 return false; 290 296 } 291 if (!target->isExtensible()) { 297 bool isExtensible = target->isExtensibleInline(exec); 298 if (exec->hadException()) 299 return false; 300 if (!isExtensible) { 292 301 throwVMTypeError(exec, ASCIILiteral("Proxy 'has' must return 'true' for a non-extensible 'target' object with a configurable property.")); 293 302 return false;
Note:
See TracChangeset
for help on using the changeset viewer.