testdata for IDEA-57411

This commit is contained in:
anna
2012-10-23 19:01:01 +02:00
parent b704249a4c
commit b40ec2d2d1
2 changed files with 19 additions and 0 deletions

View File

@@ -0,0 +1,18 @@
class A<S> {
<T> T foo(T x, S y){
return x;
}
}
class B<S> extends A<S> {
Object foo(Object x, Object y){
return x;
}
}
<error descr="'foo(T, S)' in 'A' clashes with 'foo(Object, Object)' in 'B'; both methods have same erasure, yet neither overrides the other">class C extends B<String></error> {
@Override
<T> T foo(T x, String y) {
<error descr="Incompatible types. Found: 'java.lang.Object', required: 'T'">return super.foo(x, y);</error>
}
}

View File

@@ -161,6 +161,7 @@ public class GenericsHighlightingTest extends LightDaemonAnalyzerTestCase {
public void testIDEA57533() throws Exception { doTest(false); }
public void testIDEA57509() throws Exception { doTest(false); }
public void testIDEA57410() throws Exception { doTest(false); }
public void testIDEA57411() throws Exception { doTest(false); }
public void testInconvertibleTypes() throws Exception { doTest(false); }
public void testIncompatibleReturnType() throws Exception { doTest(false); }
public void testContinueInferenceAfterFirstRawResult() throws Exception { doTest(false); }