diktat
diktat copied to clipboard
Shadowing of variables detection
Diktat should be able to detect shadowed variables as it can cause serious issues.
Name shadowing can cause following issues. There should be no shadowing.
infinite loop:
fun main() {
var x = 0
while (x < 10) {
var x = 0
x++
}
}
#426 should help to create the logic next time