On Wednesday, 10 April 2013 at 05:21:40 UTC, Manu wrote:
Why are you suggesting changing scope to imply ref? This seems wrong. scope
and ref are separate, should remain that way.

To be clear, I suggested it, not Kenji. The reason scope could imply ref is that no value type is ever unsafe. If you copy the value you're passing, there's no way the reference could escape the scope, because there's no reference! A delegate has an implicit pointer and is inherently a reference type, which is why it can work with 'scope'. In all likelihood 'scope' implying 'ref' would needlessly complicate the type system, in exchange for the convenience of only having to type either 'scope' or 'ref' depending on what you wanted. But I suggested it because I at least wanted it to be discussed.

Reply via email to