Changeset 155455 in webkit for trunk/Source/JavaScriptCore


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):

Location:
trunk/Source/JavaScriptCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/ChangeLog

    r155420 r155455  
     12013-09-10  Filip Pizlo  <[email protected]>
     2
     3        jsc commandline's run() function should take extra arguments
     4        https://bugs.webkit.org/show_bug.cgi?id=121098
     5
     6        Reviewed by Michael Saboff.
     7
     8        * jsc.cpp:
     9        (functionRun):
     10
    1112013-09-09  Michael Saboff  <[email protected]>
    212
  • 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.