Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
1.5.6
-
None
-
Microsoft Windows XP [Version 5.1.2600]
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_04-b05)
Groovy Version: 1.5.6 JVM: 1.5.0_04-b05
Description
Looking at this SSCCE, the local method selectSql gets called rather than the closure, when the closure should have scope preference. Please find below reference to the discussion about this issue on the groovy-user mailing-list.
public class Tester {
private String selectSql()
public String returnSql(Closure selectSql)
{ return selectSql() }}
Tester t = new Tester()
println t.returnSql()