Welcome! Please see the About page for a little more info on how this works.

+1 vote
in Collections by

In Clojure 1.11.1:

user=> (split-at Long/MAX_VALUE [1 2 3 4 5 6])
[(1 2 3 4 5 6) ()]

In Clojure 1.12 alpha7:

user=> (split-at Long/MAX_VALUE [1 2 3 4 5 6])
Execution error (ArithmeticException) at java.lang.Math/toIntExact (Math.java:1371).

Possibly IDrop should take a long parameter (instead of int) for compatibility?

2 Answers

+1 vote
by
0 votes
by

I would have to dig out the planning on this but I think there were good reasons to do int there. Not really concerned about this particular case.

by
edited by
I seem to remember some discussion on Slack when this first dropped (in alpha 1 -- which was mid-2022!)... I'll see if I can find those threads and link them here (assuming you're on Slack to be able to read them glchapman?).

Update: all I can find so far is discussions about floating point arguments no longer being allowed (I've gone back to December 2022 so far)
...