From: Gregor Kofler on
lorlarz meinte:

> I am a long time JavaScripter

Then it shouldn't be a problem to interpret the JSLint output yourself.
Why did you start this thrad?

Gregor



--
http://www.gregorkofler.com
From: David Mark on
Garrett Smith wrote:
> David Mark wrote:
>> lorlarz wrote:
>>> On Mar 1, 6:56 pm, Stefan Weiss <krewech...(a)gmail.com> wrote:
>>>> On 02/03/10 01:32, lorlarz wrote:
>>>>
> [...]
>
>> "We ignore the following warnings from JSLint:
>>
>> "Expected an identifier and instead saw 'undefined' (a reserved word)."
>
> That JSLint Error is completely wrong. `undefined` is a property of the
> global object, not a reserved word. It is not an error and should not be
> flagged as an error.
>

Forgot to mention that the other argument passed with it is called
"window" and references the window object (of course). ISTM that I
pointed out years ago that a local reference to this mother of all host
objects is a very bad idea (due to the obvious potential for circular
references and the resulting memory leaks in IE). JSLint can't help
them there, but I tried.
From: Richard Cornford on
David Mark wrote:
> Garrett Smith wrote:
<snip>
>> My favorite one is Dojo
>> `it instanceof Array || typeof it == "array"`.
>
> Buffoons. I tried to tell them that was ridiculous, but they
> just carped about providing "proof"
<snip>

Proof of what exactly?

That there are no ECMA 262 conforming language implementations where
- typeof - operation applied to an Array object results in the string
"array"? Which doesn't need proving as that is required by "ECMA 262
conforming language implementation".

That there have never been any web browser script language
implementations based on JavaScript, JScript or/and ECMAScript where
- typeof - operation applied to an Array object results in the string
"array"? Why would they care, as they are not even attempting to support
all possible browsers, only a known set where the situation can be
objectively verified?

What is it about the - typeof x == 'array' - mistake that makes it so
hard to recognise? That if so many have made it there must be something
in it? Unquestioning trust in the people they copied their mistakes
from?

Richard.

From: David Mark on
Richard Cornford wrote:
> David Mark wrote:
>> Garrett Smith wrote:
> <snip>
>>> My favorite one is Dojo
>>> `it instanceof Array || typeof it == "array"`.
>>
>> Buffoons. I tried to tell them that was ridiculous, but they
>> just carped about providing "proof"
> <snip>
>
> Proof of what exactly?

That's what I said, but the "cutting edge JS hackers" couldn't come up
with anything more than griping.

>
> That there are no ECMA 262 conforming language implementations where -
> typeof - operation applied to an Array object results in the string
> "array"? Which doesn't need proving as that is required by "ECMA 262
> conforming language implementation".

Of course. But I don't think they have read the specs. In their minds,
there might be a browser out there that does this because that dubious
comparison must have been included for some reason.

>
> That there have never been any web browser script language
> implementations based on JavaScript, JScript or/and ECMAScript where -
> typeof - operation applied to an Array object results in the string
> "array"? Why would they care, as they are not even attempting to support
> all possible browsers, only a known set where the situation can be
> objectively verified?

In short, they are nuts. I don't know how else to explain their
behavior in this regard (among many others). Their latest and
"greatest" Website, which will ostensibly spur new interest in their
project uses jQuery (1.2x no less) for God's sake.

Another example is that when somebody posted some random numbers that
seemed (to them) to indicate that undeclared globals were "faster", a
chain reaction started that came within an inch of committing changes
that would un-declare all of their globals. (!) They were all very
hyped up about this "breakthrough", which was seen as a counterpoint to
the various speed improvements I introduced in my branch (which they
sullenly dismissed by posting still more random numbers).

I finally headed that one off at the Trac-level by pointing out that the
aforementioned random numbers didn't indicate that at all (as well as
the fact that using undeclared variables was insane and could easily
lead to major problems in one of the browsers they profess to care about).

>
> What is it about the - typeof x == 'array' - mistake that makes it so
> hard to recognise? That if so many have made it there must be something
> in it? Unquestioning trust in the people they copied their mistakes from?
>

Probably. Judging from their rate of adoption of my many suggestions
(they are actually starting to scavenge some of them now, copying and
pasting without any real understanding), they trust unknown incompetents
more than they trust me. Like I said, nuts.
From: David Mark on
David Mark wrote:
> Richard Cornford wrote:
>> David Mark wrote:
>>> Garrett Smith wrote:
>> <snip>
>>>> My favorite one is Dojo
>>>> `it instanceof Array || typeof it == "array"`.
>>> Buffoons. I tried to tell them that was ridiculous, but they
>>> just carped about providing "proof"
>> <snip>
>>
>> Proof of what exactly?
>
> That's what I said, but the "cutting edge JS hackers" couldn't come up
> with anything more than griping.
>
>> That there are no ECMA 262 conforming language implementations where -
>> typeof - operation applied to an Array object results in the string
>> "array"? Which doesn't need proving as that is required by "ECMA 262
>> conforming language implementation".
>
> Of course. But I don't think they have read the specs. In their minds,
> there might be a browser out there that does this because that dubious
> comparison must have been included for some reason.
>
>> That there have never been any web browser script language
>> implementations based on JavaScript, JScript or/and ECMAScript where -
>> typeof - operation applied to an Array object results in the string
>> "array"? Why would they care, as they are not even attempting to support
>> all possible browsers, only a known set where the situation can be
>> objectively verified?
>
> In short, they are nuts. I don't know how else to explain their
> behavior in this regard (among many others). Their latest and
> "greatest" Website, which will ostensibly spur new interest in their
> project uses jQuery (1.2x no less) for God's sake.
>
> Another example is that when somebody posted some random numbers that
> seemed (to them) to indicate that undeclared globals were "faster", a
> chain reaction started that came within an inch of committing changes
> that would un-declare all of their globals. (!) They were all very
> hyped up about this "breakthrough", which was seen as a counterpoint to
> the various speed improvements I introduced in my branch (which they
> sullenly dismissed by posting still more random numbers).
>
> I finally headed that one off at the Trac-level by pointing out that the
> aforementioned random numbers didn't indicate that at all (as well as
> the fact that using undeclared variables was insane and could easily
> lead to major problems in one of the browsers they profess to care about).
>

They had actually closed the ticket. I had to re-open and invalidate it
(more than once). Looking back, I should have left them to
self-destruct. They are bitchy about any suggestions from me to this
day. They just don't like to hear from people who expose too many
mistakes. After all, if there are that many mistakes to be found, it
might call into "question" their self-described "expert" status. They
seem to care far more about their public image (and egos) than their users.

http://bugs.dojotoolkit.org/ticket/10174

Don't read it while eating, drinking and/or operating a motor vehicle. :)