Conrad said:
Well that's the crux. Language references are fine (holy even, for some
people), but the real world is a mess.
Please, the "real world" argument has already been milked for what it's
worth! All who think they live in that "real world" should finally come to
recognize that standards do not build up from thin air, but they are mostly
created by dedicated people, they keep on existing and are implemented for a
reason, that is *interoperability*. Nothing in your "real world" would work
(together), had not two or more people agreed on a standard about how to do
things. See below.
But I am not even talking about the ECMAScript Language Specification here,
I am talking about the language references, written and published by their
implementors. They should know what they implemented, should they not?
It doesn't matter if I do or do not find a reference, when for all
practical purposes, in all browsers that anyone has cared to test, alert
is window.alert. But see below.
It is reasonable to assume that because the first scripting language for the
Web defined a method to be a method of Window objects (even though those
objects were redefined later to belong not to that language but to the DOM
API instead) this is rather likely to be so in other implementations, for
the sake of compatibility and interoperability, which follows from the need
for compatibility when you want to be a serious competitor.
If the outcome of the Browser Wars shows anything, it is that despite M$ is
considered to be the winner, the "real world" is, slowly, moving to Web
standards, whereas proprietary solutions are limited to certain fields of
application. That would seem to be a natural process, given that all forms
of information interchange need a common ground to work.
In contrast, it is *not* reasonable to assume that because a subset of
superficially tested Web browsers has an alert() method of the Global Object
that must apply for all Web browsers or even all user agents. Especially
not when there is no reference material at all to back up that assumption.
I still refuse to use 'window.alert' until I'm shown one single instance
where a simple 'alert' doesn't work as expected. [...]
Fallacy: Shifting the burden of proof.
[Jeremy J Starcher]
| >> In most major browsers, "window" refers to the global object,
| >> unless overridden.
| [Thomas 'PointedEars' Lahn]
| > No, in *some* browsers it *appears* as if that were the case.
| > However, it was overlooked that a host object includes the
| > possibility to let it appear so.
And so on. I'm sure that you know the specs by heart,
Hardly. JFYI: Whenever I am referring to ES3F, I have searched through the
PDF document that I have open in the background most of the time. You could
be right if you said I might have a better idea than many subscribers of
this newsgroup on where to find what in the Spec.
and can quote them better than anyone else here.
Maybe so, but that would not seem to count. As the saying goes (CMIIW),
even the Devil can quote the Bible.
What really matters is if you can understand what you are quoting and apply
what you read in a Specification to a certain problem. I think I am not
that bad at it, but as for ECMAScript, Lasse or Richard can probably do it
better than me.
But theoretical possibilities aside, this problem does not appear to
exist in the real world. Yes I know, I state this without having tested
each and every instance out there. Still the theory stands; and what else
can we do than work with what we're given?
Maybe logic and reason instead of a number of conclusions being jumped to?
^^^ Unfortunately, I am not familiar with that abbreviation and STFW
was inconclusive so far. What does it mean?
Uh, I've sort of tried to avoid explicit profanity here... CBA is just
short for "can't be arsed". [...]
I found that meaning already but, since English is not my native language,
I was not sure how it applied here. Thanks.
PointedEars