As said in the title. There are several options to solve this problem:
- Introduce the 1-arity only for
(partition n coll), which keeps the current standard pattern. It doesn't however allow the other arities and attempting to call (partition n step) or (partition n step coll) would result to unexpected behavior. That could be solved by checks of (seqable? step-or-coll) or similar things.
- The 1-arity would be passed as a vector. That could solve the arity collision problem but itwould break the pattern.
- Introduce a function like
partition-xf that would do the work. The only issues could be that this function only returns a transducer, which is not common and that some people could expect the partition function to return a transducer if called like (partition n step), but I think it's just about getting used to it like everything else.