mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-08-26 15:27:45 +07:00
method refs: rename methods
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
class MyTest {
|
||||
|
||||
static class Foo {
|
||||
}
|
||||
|
||||
interface I {
|
||||
Foo m();
|
||||
}
|
||||
static Foo f<caret>oo() { return null; }
|
||||
|
||||
public static void main(String[] args) {
|
||||
I i = MyTest::foo;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
class MyTest {
|
||||
|
||||
static class Foo {
|
||||
}
|
||||
|
||||
interface I {
|
||||
Foo m();
|
||||
}
|
||||
static Foo bar() { return null; }
|
||||
|
||||
public static void main(String[] args) {
|
||||
I i = MyTest::bar;
|
||||
}
|
||||
}
|
||||
@@ -68,6 +68,10 @@ public class RenameMembersInplaceTest extends LightCodeInsightTestCase {
|
||||
doTestInplaceRename("Bar");
|
||||
}
|
||||
|
||||
public void testMethodWithMethodRef() throws Exception {
|
||||
doTestInplaceRename("bar");
|
||||
}
|
||||
|
||||
public void testConflictingMethodName() throws Exception {
|
||||
try {
|
||||
doTestInplaceRename("bar");
|
||||
|
||||
Reference in New Issue
Block a user