366[jslint] Re: expected a conditional statement and instead saw an assignment
- Jan 16, 2009--- In email@example.com, "Daniel Cassidy" <mail@...> wrote:
>Wow, that's good to know. I hadn't considered that possibility, and
> 2009/1/15 Daniel Cassidy <mail@...>:
> > As well as that, the two loops are *not* equivalent. The first loops
> > until it reaches *either* the end of the array or a falsy value (e.g.
> > false, zero, undefined, etc). The second always loops until the end of
> > the array.
> (granted in this specific case the DOM API guarantees the array will
> not contain any falsy values, but the same is not true for many other
if I had run into a falsy (killing the loop) it could have really
screwed something up.
Thanks for the tip!
- << Previous post in topic