Details
-
Type:
Improvement
-
Status:
Resolved
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: 2.5.1Release
-
Fix Version/s: 2.5.2.Release
-
Component/s: Testing, Running, Debugging
-
Labels:None
-
Number of attachments :
Description
In the following script, staticField, instanceField and localVariable should be visible in the debugger's variables view if a break point is positioned inside closure
new Type().method() class Type { static staticField = 1 def instanceField = 2 def method() { def localVariable = 3 def closure = { println staticField println instanceField println localVariable } closure() } }
I realize this might be very difficult or impossible to do while reusing the existing JDT code but it is definitely something that will add tremendous value as closures are at the core of most things groovy. This is one of the biggest complaints I hear about using the debugger with groovy.
Use this to see static variables. I usually keep it off when debugging with groovy since it creates so many synthetic statics that appear, but add no value.