Move range.adapter to algorithms + take() bugfixes
A lot of algorithms like lazy sort() can be also classified as adapters since it wraps the original range and allows to access the elements of the range in a particular order. The only reason why take() was in range.adapter is that take() is trivial - it doesn't change the order of elements but can turn an infinite range into finite one. This distinction between trivial and non-trivial algorithms isn't absolutely clear. So let us put all algorithms and any adapters that change the range iteration in some way into "algorithm" package to avoid any confusion later. - range.adapter is renamed into algorithm.iteration - range.adapter is deprecated - Added missing imports for take() and takeExactly() - takeExactly() doesn't wrap ranges that have slicing anymore - Voldemort structs for take() takeExactly() are now static
This commit is contained in:
@ -15,4 +15,5 @@
|
||||
module tanya.algorithm;
|
||||
|
||||
public import tanya.algorithm.comparison;
|
||||
public import tanya.algorithm.iteration;
|
||||
public import tanya.algorithm.mutation;
|
||||
|
Reference in New Issue
Block a user