On Thu, 28 Oct 2004 02:36:03 -0400, nntp <nn**@rogers.com> wrote:
I wonder what will happen if I do not use ; after each line. Will the
code still run in all browers? I saw some scripts which has lines
without ; and still working perfectly.
ECMAScript defines circumstances where semi-colons are automatically
inserted at the end of a statement, however I personally consider it to be
bad form (and I suspect others will feel the same).
The automatic insertion process is primarily an error-correction
mechanism, used to force certain types of syntax error into something more
acceptable.
I wouldn't advocate intentional omission of terminating semi-colons.
Mike
--
Michael Winter
Replace ".invalid" with ".uk" to reply by e-mail.