Thank you. It's my fault that I didn't read it carefully. 2012/3/12 Lasse Reichstein <[email protected]>
> On Mon, Mar 12, 2012 at 8:33 AM, 程劭非 <[email protected]> wrote: > > Hi all, > > Just noticed that there is no description about "name" and "length" > property > > of JSON.parse and JSON.stringify in ES5. > > Are they implement-dependent? > > > > (I saw test262 require JSON.stringify.length to be 3, but no such case > > for JSON.parse. ) > > The first part of section 15 says: > "Every built-in Function object described in this clause―whether as a > constructor, an ordinary function, or both―has a length property whose > value is an integer. Unless otherwise specified, this value is equal > to the largest number of named arguments shown in the subclause > headings for the function description, including optional parameters." > > I.e., the lengths are specified. > I don't believe the name properties for function objects are specified > anywhere in ES5, so they are entirely outside the spec. > > /L >
_______________________________________________ es-discuss mailing list [email protected] https://mail.mozilla.org/listinfo/es-discuss

