Consider the following:
class Foo {
private String field
}
class Bar extends Foo {
def baz() {
field
}
}
Execution of "new Bar().baz()" results in: groovy.lang.MissingPropertyException: No such property: field for class: Bar
However, type inferencing shows that the occurrence of "field" within baz() infers to "Foo.field".
Consider the following:
Execution of "new Bar().baz()" results in: groovy.lang.MissingPropertyException: No such property: field for class: Bar
However, type inferencing shows that the occurrence of "field" within baz() infers to "Foo.field".