apparently this is valid: (nth [3] -1 2147483647)
, I need to change tha specz
what do you think is not valid?
oh, you scoped the index just to nat-int?, but there is behavior defined for out-of-range values
it’s in the docstring
yes, I missed it. didn’t expect anyone to use it like this, but coal-mine detected one 🙂
interestingly, this only manifested in CLJS. I’m going to check why…
inlining in CLJ, not in CLJS
(nth [3] 0.1 1) ;;=> 3
:thinking_face:I’m going to change the spec to int?
instead of nat-int
, that should be sufficient
oh, I didn’t write this spec, but I did review it, so still my bad 😉
fixed
Yes, int? seems right