Creation of the `arguments` object

Mathias Bynens mathias at qiwi.be
Wed Jul 4 08:30:48 PDT 2012


> In the execution phase, their behavior is different.
>
> section 12.2
> http://ecma-international.org/ecma-262/5.1/#sec-12.2
>
>     var arguments = undefined
>
> performs PutValue with reference and undefined.
>
>> 1. Let lhs be the result of evaluating Identifier as described in 11.1.2.
>> 2. Let rhs be the result of evaluating Initialiser.
>> 3. Let value be GetValue(rhs).
>> 4. Call PutValue(lhs, value).
>> 5. Return a String value containing the same sequence of characters as in
>> the Identifier.
>
>
> But
>
>    var arguments;
>
> doesn't perform any assignment.
>
>> 1. Return a String value containing the same sequence of characters as in
>> the Identifier.

Thanks, Yusuke!


More information about the es-discuss mailing list