Community
Participate
Working Groups
Created attachment 124551 [details] screenshot Eclipse Build ID: I20090129-1800 WTP Build ID: 3.1M4-20081219210304 Dojo Plugins: 1.0.0.v20080508-1557 1) create a javascript file, paste the following code: (function() { function a(){ return 0; } var x= a(); })(); observe: there's an error decoration indicating "Unreachable code". This is not expected. see attached screenshot 2) add a semicolon at the end of line 4 observe: now "};" is marked as unreachable code
Created attachment 133661 [details] Updates in analyseCode() method of MethodDeclaration class.
Updated the analyseCode() method to handle the special case of a function declared inside another function. This is similar to the way this is done CompiliationUnitDeclaration. Can be patched in 3.0.5 and 3.1. Will add junits for this tomorrow.
Approved. Thanks, Chris.
.
Was there a problem with this patch Nitin?
Fixed.