This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defn get-int-from-byte-quad [byte-quad] | |
(loop [shift-amount 24 | |
quad byte-quad | |
result 0] | |
(if quad | |
result | |
(recur (- shift-amount 8) | |
(next quad) | |
(bit-or result (bit-shift-left (bit-and 0xff (first quad)) shift- amount)))))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment