Re: [elixir-core:10486] [Proposal] List.rotate/4

2021-10-20 Thread José Valim
Great job! I think you can simplify this to require ranges to always have a step of 1. So decreasing ranges will need an explicit //1. We want to do this for slice, but we can't yet because of backwards compatibility. If we have a plan to add this to Enum, then we should add it to Enum now, to

Re: [elixir-core:10486] [Proposal] List.rotate/4

2021-10-20 Thread Tyler Young
My draft implementation (and the associated @doc and test suite ) has been updated to match the range semantics of Enum.slice/2. Among other things, that