https://issues.dlang.org/show_bug.cgi?id=15582

--- Comment #2 from Marc Schütz <[email protected]> ---
(In reply to b2.temp from comment #1)
> I don't aggree, it's like if you say that
> 
> s.opSlice() = 10;
> 
> should work.

That should work, too.

Note that appending another pair of brackets is already accepted. As long as
there's no ambiguity with assigning to the slice itself (i.e. the lhs is not an
lvalue, and opSlice doesn't return by ref), it should just do the appropriate
element-wise operation.

Analogously with *=, += etc.

--

Reply via email to