Skip to content

Failed

org.eclipse.jdt.core.tests.compiler.regression.JEP286Test.testBug532349_003 - 10 (from org.eclipse.jdt.core.tests.compiler.regression.TestAll)

Failing for the past 22 builds (Since #111 )
Took 1 sec.

Error Message

testBug532349_003 - Javac found error(s) but Eclipse did not find any.
----------- Expected ------------

------------ but was ------------
X.java:2: error: type argument ? extends I is not within bounds of type-variable T\n
 public static void foo(Y<? extends I> y) {\n
                          ^\n
  where T is a type-variable:\n
    T extends Integer declared in class Y\n
1 error\n

--------- Difference is ----------
 expected:<[]> but was:<[X.java:2: error: type argument ? extends I is not within bounds of type-variable T\n
 public static void foo(Y<? extends I> y) {\n
                          ^\n
  where T is a type-variable:\n
    T extends Integer declared in class Y\n
1 error\n
]>

Stacktrace

junit.framework.ComparisonFailure: 
testBug532349_003 - Javac found error(s) but Eclipse did not find any.
----------- Expected ------------

------------ but was ------------
X.java:2: error: type argument ? extends I is not within bounds of type-variable T\n
	public static void foo(Y<? extends I> y) {\n
	                         ^\n
  where T is a type-variable:\n
    T extends Integer declared in class Y\n
1 error\n

--------- Difference is ----------
 expected:<[]> but was:<[X.java:2: error: type argument ? extends I is not within bounds of type-variable T\n
	public static void foo(Y<? extends I> y) {\n
	                         ^\n
  where T is a type-variable:\n
    T extends Integer declared in class Y\n
1 error\n
]>
	at org.eclipse.jdt.core.tests.compiler.regression.JEP286Test.testBug532349_003(JEP286Test.java:886)

Standard Output

org.eclipse.jdt.core.tests.compiler.regression.JEP286Test#testBug532349_003 - 10
X.java [
class X {
	public static void foo(Y<? extends I> y) {
		var v = y.t;
		Integer dsbType0 = v;
		I i = v;
	}
}
interface I { }
class Y<T extends Integer> {
	public T t;
}
]


Full results sent to /tmp/comptest/run.1584245034298/10.0.2_20200315_040443.txt

Standard Error

--- javac err: ---
X.java:2: error: type argument ? extends I is not within bounds of type-variable T
	public static void foo(Y<? extends I> y) {
	                         ^
  where T is a type-variable:
    T extends Integer declared in class Y
1 error

----------------------------------------