Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
4.0.2
-
None
Description
Consider the following:
public class JavaBean<T> { private T value; public T getValue() { return value; } public void setValue(T value) { this.value = value; } }
@groovy.transform.CompileStatic class Outer extends groovy.transform.stc.JavaBean<Inner> { static class Inner { String string } def bar() { { -> value.string }.call() // "value" is parameterized property } } def foo = new Outer(value: new Outer.Inner(string:'hello world')) assert foo.bar() == 'hello world'
"Access to T#string is forbidden"