Re: for..in, hasOwnProperty(), and inheritance

2011-11-08 Thread Luke Smith
Brendan EichNovember 8, 2011 11:59 AM On Nov 8, 2011, at 11:48 AM, Felipe Gasper wrote: Actually, have you ever seen a use case of wanting to prevent iteration through inherited properties *other* than Object.prototype? (Besides using for..in on Array objects.) Sure. People make "cl

Date vs Daylight Savings

2011-03-10 Thread Luke Smith
The consistent behavior across all browsers of Date when passed a time made invalid by a DST jump is to roll the time *back* by an hour. // On a system with Pacific TZ new Date(2011, 2, 13, 2, 0, 0, 0); Sun Mar 13 2011 01:00:00 GMT-0800 (PST) Mainly out of curiosity, is there a thread or a simp

Re: JSON parser grammar

2010-06-22 Thread Luke Smith
On Jun 22, 2010, at 7:20 PM, Oliver Hunt wrote: On Jun 22, 2010, at 7:07 PM, Dean Landolt wrote: On Tue, Jun 22, 2010 at 9:34 PM, Oliver Hunt wrote: But that's the rub -- the JSON spec cannot be changed. It (intentionally) has no version number. ECMA could superset it -- ES- JSON, i

Re: Property Iteration in JSON serialization

2009-10-13 Thread Luke Smith
On Oct 13, 2009, at 9:24 PM, Brian Kardell wrote: There are potentially some additional practical upshots beyond human readability to this which I won't get into here until I find out: Is it even plausible to accomplish this with new built in JSON supports? To be specific, if it's not clear.

Re: arguments.callee in Harmony

2009-09-24 Thread Luke Smith
The use of named function expressions is not correctly implemented by at least IE 6-8. The basic use case works fine (e.g.) var foo = function callee() { // do something setTimeout(callee, 10); }; But declared as (function callee() { // do something setTimeout(callee, 10); })()

Re: more JSON spec questions

2009-08-26 Thread Luke Smith
I shared this on the JSON Yahoo! group list, but this seems relevant here, now. I extracted tests from the YUI JSON test suite for Native JSON support. http://github.com/lsmith/JSON-test-suite/tree/master Great to see the sharing of tests! Luke On Aug 26, 2009, at 3:37 PM, Oliver Hunt wrot

Re: Callable RegExp vs. typeof (was: Re: Draft of Function.prototype.bind.)

2009-08-13 Thread Luke Smith
On Aug 13, 2009, at 1:44 PM, Brendan Eich wrote: ES3 Chapter 16 says: "An implementation may provide additional types, values, objects, properties, and functions beyond those described in this specification. This may cause constructs (such as looking up a variable in the global scope) to