Changeset 223584 in webkit for trunk/Source/JavaScriptCore/dfg/DFGOperations.cpp
- Timestamp:
- Oct 17, 2017, 4:34:29 PM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/dfg/DFGOperations.cpp
r223523 r223584 53 53 #include "JSFixedArray.h" 54 54 #include "JSGenericTypedArrayViewConstructorInlines.h" 55 #include "JSGlobalObjectFunctions.h"56 55 #include "JSLexicalEnvironment.h" 57 56 #include "JSMap.h" … … 2520 2519 } 2521 2520 2522 EncodedJSValue JIT_OPERATION operationGetPrototypeOfObject(ExecState* exec, JSObject* thisObject)2523 {2524 VM& vm = exec->vm();2525 NativeCallFrameTracer tracer(&vm, exec);2526 return JSValue::encode(thisObject->getPrototype(vm, exec));2527 }2528 2529 EncodedJSValue JIT_OPERATION operationGetPrototypeOf(ExecState* exec, EncodedJSValue encodedValue)2530 {2531 VM& vm = exec->vm();2532 NativeCallFrameTracer tracer(&vm, exec);2533 auto scope = DECLARE_THROW_SCOPE(vm);2534 2535 JSValue thisValue = JSValue::decode(encodedValue).toThis(exec, StrictMode);2536 if (thisValue.isUndefinedOrNull())2537 return throwVMError(exec, scope, createNotAnObjectError(exec, thisValue));2538 2539 JSObject* thisObject = jsDynamicCast<JSObject*>(vm, thisValue);2540 if (!thisObject) {2541 JSObject* prototype = thisValue.synthesizePrototype(exec);2542 EXCEPTION_ASSERT(!!scope.exception() == !prototype);2543 if (UNLIKELY(!prototype))2544 return JSValue::encode(JSValue());2545 return JSValue::encode(prototype);2546 }2547 2548 scope.release();2549 return JSValue::encode(thisObject->getPrototype(vm, exec));2550 }2551 2552 2521 void JIT_OPERATION operationThrowDFG(ExecState* exec, EncodedJSValue valueToThrow) 2553 2522 {
Note:
See TracChangeset
for help on using the changeset viewer.