Escape analysis

Jason House jason.james.house at gmail.com
Tue Oct 28 06:15:12 PDT 2008


Walter Bright Wrote:

> Jason House wrote:
> >> scope is a storage class, not a type constructor.
> > 
> > How do you treat members of objects passed in? If I pass in a struct
> > with a delegate in it, is it treated as scope too? What if it's an
> > array? A class?
> 
> The scope applies to the bits of the object, not what they may refer to.

This seems rather limiting. I know this is aimed at addressing the dynamic closure problem. This solution would mean that I can't encapsulate delegates. Ideally, I should be able to declare my encapsulating struct as scope or noscope and manage the member delegate accordingly.



More information about the Digitalmars-d mailing list