Ignore:
Timestamp:
Sep 10, 2013, 10:53:40 AM (12 years ago)
Author:
[email protected]
Message:

jsc commandline's run() function should take extra arguments
https://bugs.webkit.org/show_bug.cgi?id=121098

Reviewed by Michael Saboff.

  • jsc.cpp:

(functionRun):

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/jsc.cpp

    r155402 r155455  
    390390    GlobalObject* globalObject = GlobalObject::create(exec->vm(), GlobalObject::createStructure(exec->vm(), jsNull()), Vector<String>());
    391391
     392    JSArray* array = constructEmptyArray(globalObject->globalExec(), 0);
     393    for (unsigned i = 1; i < exec->argumentCount(); ++i)
     394        array->putDirectIndex(globalObject->globalExec(), i - 1, exec->argument(i));
     395    globalObject->putDirect(
     396        exec->vm(), Identifier(globalObject->globalExec(), "arguments"), array);
     397
    392398    JSValue exception;
    393399    StopWatch stopWatch;
Note: See TracChangeset for help on using the changeset viewer.