Il 24/11/2017 01:46, Jochen Theodorou ha scritto:
In my opinion the test is wrong, but I'd like to hear others about this.

And another point. We seem to have no similar test for dynamic Groovy. Groovy does use direct field access if the field is available on "this". But the question here is if that extends to all super classes. In my opinion it should.

If I get no vetos I will push a fix for this for all current groovy versions

I don't know if I understood it right, but are you saying that you think that invoking b.usingGetter() in your example should not call A.getX(), but rather access A.x directly? And that, I guess, the same policy should apply for the corresponding setter? I guess you think so because A.x is declared as protected, don't you? Because if A.x had no modifier, I think that such a change may break a lot of code that assumes getter/setter are called, in particular I'm thinking of the write access case for @Bindable fields.

Mauro

Reply via email to