javascript-in-one-pic icon indicating copy to clipboard operation
javascript-in-one-pic copied to clipboard

Bitwise operators

Open Tarabass opened this issue 10 years ago • 3 comments

Are bitwise operators coming? https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Bitwise_Operators

Tarabass avatar Jun 26 '15 19:06 Tarabass

@Tarabass I thought it was not very commonly used, but I've received couple of suggestions about this, so I put it on the TODO list, thx~

rainyear avatar Jun 27 '15 02:06 rainyear

:+1:

dhenson02 avatar Jun 27 '15 04:06 dhenson02

@rainyear there are people like me that do stuff like:

if (~foo.indexOf("bar"))

and something like:

var min = sec / 60 | 0;
sec %= 60;

so please keep in mind people use them for other purposes aswell.

GottZ avatar Jun 29 '15 09:06 GottZ