Paul Evans
Paul Evans
> If my code sample doesn't address your issue, can you help me understand why? @HaraldJoerg mostly explained that in the reply; I expanded on it above. > If this...
@HaraldJoerg > Here's an example which can be made to work with Moose, but not with Object::Pad: Ah, that example is showing off an equally-valid, yet quite different problem. That's...
Wow, much good thought here I see. I'll respond to a few quick bits to get them out of my head but I will write up a longer response later...
Given the questions above, there are now a few ideas for test cases. In each case, what should the correct behaviour be? Should it be a compiletime failure? If not...
My personal feeling is that we should use model 1 (`my`-like). This would make Test2 pass as is written. Test1 should probably compile OK but yield a warning, something about...
@Ovid > I much prefer the `my`-like solution. I would probably write it like this: > {code with `field` inside `method` Yeah that makes sense. Once you can hide a...
Hrm; @HaraldJoerg makes a good point. If they do scope the same way as `my` lexicals, it somewhat cuts off the ability to ever do subclass-visible fields in future. Whereas...
Thinking further about inheritable fields for subclassing, I think it can be done within the syntax, while still keeping a lexical-like model. The trick is to be explicit about which...
Various thoughts above seem to be converging on the idea that we can have both toplevel fields at full class scope, and buried fields within smaller scopes or individual methods....
@Ovid > If we go this route, I would instead suggest something like this: > ... That would be quite a significant departure from what we have now. Currently Perl...