On the subject of properties, and possibility of having them in the library
Maxim Fomin
maxim at maxim-fomin.ru
Sat Jan 26 07:31:35 PST 2013
On Saturday, 26 January 2013 at 14:41:43 UTC, Simen Kjaeraas
wrote:
> Now, the obstacle here is I can't refer to _n in those lambdas.
> Why not? I'm guessing the struct has no context member, and the
> lambdas don't because the class is not yet instantiated. Could
> this be fixed? I think so, and I think this is a feature with
> benefits beyond simple properties.
Structs inside classes do not have access to outer scope (no
outer property, no context pointer). Last time it was discussed
month ago. There is probably a bugzilla issue for this but it
seems it would not be fixed soon, let alone there were no
consensus that it should work.
More information about the Digitalmars-d
mailing list