Changeset 34578 in webkit for trunk/JavaScriptCore/VM/Machine.cpp
- Timestamp:
- Jun 15, 2008, 7:19:08 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/JavaScriptCore/VM/Machine.cpp
r34541 r34578 104 104 return n1 < n2; 105 105 106 return static_cast<const StringImp*>(p1)->value() < static_cast<const StringImp*>(p2)->value();106 return static_cast<const JSString*>(p1)->value() < static_cast<const JSString*>(p2)->value(); 107 107 } 108 108 … … 119 119 return n1 <= n2; 120 120 121 return !(static_cast<const StringImp*>(p2)->value() < static_cast<const StringImp*>(p1)->value());121 return !(static_cast<const JSString*>(p2)->value() < static_cast<const JSString*>(p1)->value()); 122 122 } 123 123 … … 156 156 return jsNumber(v1->uncheckedGetNumber() + v2->uncheckedGetNumber()); 157 157 if (bothTypes == ((StringType << 3) | StringType)) { 158 UString value = static_cast< StringImp*>(v1)->value() + static_cast<StringImp*>(v2)->value();158 UString value = static_cast<JSString*>(v1)->value() + static_cast<JSString*>(v2)->value(); 159 159 if (value.isNull()) 160 160 return throwOutOfMemoryError(exec); … … 450 450 int errLine; 451 451 UString errMsg; 452 RefPtr<EvalNode> evalNode = exec->parser()->parse<EvalNode>(exec, UString(), 1, UStringSourceProvider::create(static_cast< StringImp*>(program)->value()), &sourceId, &errLine, &errMsg);452 RefPtr<EvalNode> evalNode = exec->parser()->parse<EvalNode>(exec, UString(), 1, UStringSourceProvider::create(static_cast<JSString*>(program)->value()), &sourceId, &errLine, &errMsg); 453 453 454 454 if (!evalNode) { … … 685 685 } 686 686 687 JSValue* Machine::execute(FunctionBodyNode* functionBodyNode, ExecState* exec, FunctionImp* function, JSObject* thisObj, const List& args, RegisterFileStack* registerFileStack, ScopeChainNode* scopeChain, JSValue** exception)687 JSValue* Machine::execute(FunctionBodyNode* functionBodyNode, ExecState* exec, JSFunction* function, JSObject* thisObj, const List& args, RegisterFileStack* registerFileStack, ScopeChainNode* scopeChain, JSValue** exception) 688 688 { 689 689 if (m_reentryDepth >= MaxReentryDepth) { … … 2539 2539 } 2540 2540 2541 JSValue* Machine::retrieveArguments(ExecState* exec, FunctionImp* function) const2541 JSValue* Machine::retrieveArguments(ExecState* exec, JSFunction* function) const 2542 2542 { 2543 2543 Register** registerBase; … … 2558 2558 } 2559 2559 2560 JSValue* Machine::retrieveCaller(ExecState* exec, FunctionImp* function) const2560 JSValue* Machine::retrieveCaller(ExecState* exec, JSFunction* function) const 2561 2561 { 2562 2562 Register** registerBase; … … 2575 2575 } 2576 2576 2577 bool Machine::getCallFrame(ExecState* exec, FunctionImp* function, Register**& registerBase, int& callFrameOffset) const2577 bool Machine::getCallFrame(ExecState* exec, JSFunction* function, Register**& registerBase, int& callFrameOffset) const 2578 2578 { 2579 2579 callFrameOffset = exec->m_callFrameOffset; … … 2597 2597 } 2598 2598 2599 void Machine::getFunctionAndArguments(Register** registerBase, Register* callFrame, FunctionImp*& function, Register*& argv, int& argc)2600 { 2601 function = static_cast< FunctionImp*>(callFrame[Callee].u.jsValue);2602 ASSERT(function->inherits(& FunctionImp::info));2599 void Machine::getFunctionAndArguments(Register** registerBase, Register* callFrame, JSFunction*& function, Register*& argv, int& argc) 2600 { 2601 function = static_cast<JSFunction*>(callFrame[Callee].u.jsValue); 2602 ASSERT(function->inherits(&JSFunction::info)); 2603 2603 2604 2604 argv = (*registerBase) + callFrame[CallerRegisterOffset].u.i + callFrame[ArgumentStartRegister].u.i + 1; // skip "this"
Note:
See TracChangeset
for help on using the changeset viewer.