On Thursday, 9 January 2014 at 14:25:20 UTC, Benjamin Thaut
wrote:
The best example in D is the deprection of indexOf. Now you
have to call countUntil. But if I have to choose between the
two names, indexOf actually tells me what it does, while
countUntil does not. count until what?
std.algorithm.indexOf was deprecated, not std.string.indexOf, so
you can still use it of course and it still gives you the byte
(array-access) index of the supplied parameter. And countUntil
counts elements until it finds the supplied parameter. I think
this is logical and useful and easy to understand.