Peter Alexander:
(or equivalently, one range with an iteration policy).
If no other better solution is found, one range with an iteration policy is acceptable, in my opinion.
(By the way, what's the API of your functions? In similar generators I usually add a boolean doCopy template argument, that defaults to true. If it's true, the generator yields different buffers, otherwise it yields always the same modified buffer. This allows to have both convenience & safety on default, and speed on request).
Bye, bearophile
