sdk
sdk copied to clipboard
Renaming constructor that shares name with instance member results in invalid code
Repro:
class Foo {
Foo.bar() {
bar();
}
void bar() {}
}
If you rename the constructor Foo.bar(), it makes the instance method call to bar inside the body be renamed too, with an added leading ..
Result:
class Foo {
Foo.newName() {
.newName();
}
void bar() {}
}