(int-in-range? start end val)
Return true if start <= val, val < end and val is a fixed
precision integer.
Source
(defn
int-in-range?
"Return true if start <= val, val < end and val is a fixed\n precision integer."
[start end val]
(cond
(integer? val)
(c/and (<= start val) (< val end))
(instance? goog.math.Long val)
(c/and (.lessThanOrEqual start val) (.lessThan val end))
(instance? goog.math.Integer val)
(c/and (.lessThanOrEqual start val) (.lessThan val end))
:else
false))