On 12.07.2017 17:48, Daniel Sun wrote:
Hi all,
If no one is opposed to deprecating the weird feature, I'll modify
the two tests at the weekend(shouldCompile -> shouldNotCompile):
https://github.com/apache/groovy/blob/master/src/test/gls/scope/MultipleDefinitionOfSameVariableTest.groovy#L110
https://github.com/apache/groovy/blob/master/src/test/gls/scope/MultipleDefinitionOfSameVariableTest.groovy#L119
sorry, but veto.
class X {
String foo
private foo
}
declares for example a get/setFoo for String, while the backing field is
Object. The field also allows you to use additional modifiers like
volatile for example.
bye Jochen