Changeset 38268 in webkit for trunk/JavaScriptCore/API/JSCallbackObjectFunctions.h
- Timestamp:
- Nov 10, 2008, 12:25:35 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/JavaScriptCore/API/JSCallbackObjectFunctions.h
r38265 r38268 128 128 JSLock::DropAllLocks dropAllLocks(exec); 129 129 if (JSValueRef value = getProperty(ctx, thisRef, propertyNameRef.get(), toRef(exec->exceptionSlot()))) { 130 // cache the value so we don't have to compute it again 131 // FIXME: This violates the PropertySlot design a little bit. 132 // We should either use this optimization everywhere, or nowhere. 133 slot.setCustom(toJS(value), cachedValueGetter); 130 slot.setValue(toJS(value)); 134 131 return true; 135 132 } … … 431 428 432 429 template <class Base> 433 JSValue* JSCallbackObject<Base>::cachedValueGetter(ExecState*, const Identifier&, const PropertySlot& slot)434 {435 JSValue* v = slot.slotBase();436 ASSERT(v);437 return v;438 }439 440 template <class Base>441 430 JSValue* JSCallbackObject<Base>::staticValueGetter(ExecState* exec, const Identifier& propertyName, const PropertySlot& slot) 442 431 {
Note:
See TracChangeset
for help on using the changeset viewer.