JRS: In article <59************ *************** @msgid.meganews servers.co
m>, dated Sun, 20 Feb 2005 08:04:58, seen in news:comp.lang. javascript,
Douglas Crockford <no****@covad.n et> posted :
In JavaScript arrays,
The value of a missing element is undefined.
That's either ambiguous or wrong, considering it on its own; and,
considering its author, it cannot be wrong.
The value of a missing element is defined, and it is defined as the
special value called undefined. That value itself is well-defined,
although its internal representation probably is not.
[][0] == [][1] evaluates, by definition AIUI, as the value true.
In discussing javascript, undefined should not be used to mean not-
defined; but, lest it be so misinterpreted, neither should it be used
unaided to mean what it rightly means.
--
© John Stockton, Surrey, UK. ?@merlyn.demon. co.uk Turnpike v4.00 IE 4 ©
<URL:http://www.jibbering.c om/faq/> JL/RC: FAQ of news:comp.lang. javascript
<URL:http://www.merlyn.demo n.co.uk/js-index.htm> jscr maths, dates, sources.
<URL:http://www.merlyn.demo n.co.uk/> TP/BP/Delphi/jscr/&c, FAQ items, links.