дзеркало
https://github.com/l0ng-ai/openidea.git
синхронізовано 2026-12-03 16:51:16 +02:00
fix(java): go to an interface method implemented by a superclass (#7781)
Go to Implementation on an interface method found nothing when the implementing class inherits the method from a superclass that does not implement the interface itself. The superclass's method is now listed, once however many classes inherit it. Closes #7760
Цей коміт міститься в:
1 джерело
82fdd97588
коміт
e86e28ae63
3 files changed
+45
-1
No files matched your search
@@ -86,6 +86,29 @@ public class Words implements SubRepo {
|
||||
return "words";
|
||||
}
|
||||
}
|
||||
''',
|
||||
'Handler.java': '''package zoo;
|
||||
|
||||
public interface Handler {
|
||||
void handle();
|
||||
}
|
||||
''',
|
||||
'BaseHandler.java': '''package zoo;
|
||||
|
||||
public class BaseHandler {
|
||||
public void handle() {
|
||||
}
|
||||
}
|
||||
''',
|
||||
'HandlerImpl.java': '''package zoo;
|
||||
|
||||
public class HandlerImpl extends BaseHandler implements Handler {
|
||||
}
|
||||
''',
|
||||
'OtherHandler.java': '''package zoo;
|
||||
|
||||
public class OtherHandler extends BaseHandler implements Handler {
|
||||
}
|
||||
''',
|
||||
'Task.java': '''package zoo;
|
||||
|
||||
@@ -246,6 +269,8 @@ try:
|
||||
('Repo.java', 'save(T'): (['Anon.java:5', 'Anon.java:9', 'Longs.java:0', 'Numbers.java:3', 'Words.java:3'], True),
|
||||
('Use.java', 'save("x")'): (['Anon.java:5', 'Anon.java:9', 'Longs.java:0', 'Numbers.java:3', 'Words.java:3'], True),
|
||||
('Repo.java', 'name()'): (['Words.java:6'], True),
|
||||
# Implemented by a superclass of the implementing classes, listed once.
|
||||
('Handler.java', 'handle()'): (['BaseHandler.java:3'], True),
|
||||
# A library type's implementations in the sources; the library has more.
|
||||
('Use.java', 'Runnable task'): (['Task.java:2'], False),
|
||||
('Use.java', 'run();'): (['Task.java:3'], False),
|
||||
|
||||
Reference in new issue
Заблокувати користувача