Introduce inspection detecting self-assignment of properties
So #KT-20714 Fixed
This commit is contained in:
committed by
Mikhail Glukhikh
parent
ffa9478d0c
commit
204d9e3423
@@ -0,0 +1,13 @@
|
||||
// PROBLEM: Variable 'foo' is assigned to itself
|
||||
// WITH_RUNTIME
|
||||
// FIX: Remove self assignment
|
||||
|
||||
class Test {
|
||||
var foo = 1
|
||||
|
||||
fun test() {
|
||||
with (Test()) {
|
||||
this.foo = <caret>foo
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user