do-while grammar

Geoffrey Garen ggaren at
Tue Feb 8 11:59:58 PST 2011

FWIW, JavaScriptCore provides automatic semicolon insertion after all do-while statements in all contexts. We made this change for web compatibility, mimicking a Firefox quirk.


On Feb 8, 2011, at 11:53 AM, Dave Fugate wrote:

> Just to confirm, do-while iteration statements do in fact require a semi-colon at the end as indicated in 12.6.1 of ES5, correct?  That is, a production of the nature:
>                 do {;} while (false) false;
> would be invalid JavaScript as doesn’t meet any of the three rules set out in 7.9.1,  right?
> Thanks,
> Dave
> _______________________________________________
> es-discuss mailing list
> es-discuss at

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the es-discuss mailing list