> > From: Michael Geary > > It's pretty rare for anything like this to depend on the > > compiler or interpeter.
> From: Pops > We are still talking about short circuits? I think so. :-) > For bitwise conditions. It can be larged based on only > compiler/ interpreter but machine word size. This is in > fact, a could be a common bug in code: > > if (a & b) .... versus if ((a & b) == b) .... > > depending on the language compiler/interpreter, the machine > word size and the language word size. The latter is 100% > guarantee to be correct, the former, you typically is ok, but > you can not be confident that it will be. What language are you talking about? "if( a & b )" is perfectly good, portable code in either C (assuming reasonable types for a and b) or JavaScript. > > Operator semantics are a pretty basic part of the core JavaScript > > language, and you should be able to count on that > > expression working the same in any JavaScript implementation. > Is that basically because there is only one JavaScript source > everyone is using? :-) No, but there is one standard they are all using: http://www.ecma-international.org/publications/standards/Ecma-262.htm -Mike