I have tried to implement a simple flatten function for
multidimensional arrays with recursive templates but got stuck.
Then I googled a little and stumped into complex
which requires your arrays to be either TreeList or Algebraic.
That is, it does not work out-of-the-box on something like
I'd like to clarify a couple of questions first.
How come Phobos doesn't have "flatten" function for arrays?
Is there an implementation of flatten that works out-of-the-box
on N-dim arrays outside of Phobos? Excluding "flattened" from
mir.ndslice since it works on Slices.