On Tuesday, 6 March 2018 at 17:41:42 UTC, H. S. Teoh wrote:
Yeah, Andrei has admitted before that this is probably what he
would do today, if he were given a second chance to design
ranges. But at the time, the landscape of D was rather
different, and certain language features didn't exist yet
(sorry, can't recall exactly which off the top of my head), so
he settled with the compromise that we have today.
As they say, hindsight is always 20/20. But it wasn't so easy
to foresee the consequences at the time when the very concept
of ranges was still brand new.
Andrei's 'On Iteration' was published 2009-11-09. Postblits
had been in the language for about a year and a half, and
@disable arrived early 2010. Both features were probably too
new to warrant being an integral part of the design of ranges.