"Timon Gehr" <[email protected]> wrote in message news:[email protected]... > >> The only advantages slices have left >> are (a) type syntax, i.e. T[] instead of Slice!T, (b) literal syntax, >> i.e. [ 1, 2, 3 ] instead of slice(1, 2, 3), and (c) a couple of stray >> language bugs such as '$'. > > I am thankful for $, as it is a great feature, and it really should be > made accessible to user defined types. Either through opDollar or the > rewrite a[foo($)] => a[foo(a.length)]. What makes it qualify as a stray > language bug to you? >
He's saying that one of the few advantages slices have left over user-defined types is that, for slices, $ actually works. The bug is that it doesn't work for user-defined types. FWIW, I like the rewrite idea far better than opDollar.
