function/macrosince v0.0-927 clojure.core/bit-andEdit
(bit-and x y)
(bit-and x y & more)


Bitwise "and". Same as x & y in JavaScript.


Bits can be entered using radix notation:

(bit-and 2r1100 2r1010)
;;=> 8
;; 8 = 2r1000

Same numbers in decimal:

(bit-and 12 10)
;;=> 8

See Also:

Source docstring:
Bitwise and
Function code @ clojurescript:src/main/cljs/cljs/core.cljs
(defn bit-and
  ([x y] (cljs.core/bit-and x y))
  ([x y & more]
     (reduce bit-and (cljs.core/bit-and x y) more)))

Macro code @ clojurescript:src/main/clojure/cljs/core.cljc
(core/defmacro ^::ana/numeric bit-and
  ([x y] (core/list 'js* "(~{} & ~{})" x y))
  ([x y & more] `(bit-and (bit-and ~x ~y) ~@more)))