I'm not sure if this question is suitable for SO or not. I will remove if it is not.
I need to review some KLOC code. As part of this, I need to find out the depth of the loops and check the status. [Cm. Examples below]
If it is more than five remedies, I need to note this.
My question is: "Is there any tool that could do this for me?" I searched google but got no answer.
Example 1: for {}// Block depth 1
Example 2: for { if () {} }// Block Depth 2
Example 3: for () { for () { if() {} } }// Block Depth 3
source
share