method conflicts: prefer method with more specific return type (IDEA-67570)

This commit is contained in:
anna
2013-01-08 13:44:08 +01:00
parent 5f7a5c98d7
commit 93a7d9f158
4 changed files with 24 additions and 2 deletions
@@ -0,0 +1,21 @@
interface A1
{
String foo();
}
interface B1
{
Object foo();
}
class C1<T extends B1 & A1> {
void bar(T x) {
String foo = x.foo();
}
}
class C2<T extends A1 & B1> {
void bar(T x) {
String foo = x.foo();
}
}