digitalmars.D - Suggestion for another operator: slice assign
- Russ Lewis (13/13) Nov 14 2004 I find myself doing the following sometimes:
I find myself doing the following sometimes: T[] array = <something>; if(<whatever) { Process(array[0]); array = array[1..length]; } Which made me think that a slice-assign operator would make a lot of sense; it would be a good parallel with += *= and the rest. What I imagined was something like: array =[1..length]; Which isn't 100% consistent with the others, of course, since the operator comes AFTER the =, but it's close. Thoughts?
Nov 14 2004