<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<div class="moz-cite-prefix">Vicente,<br>
this seems to be caused by this change in TL<br>
<br>
<meta http-equiv="content-type" content="text/html;
charset=ISO-8859-1">
<a
href="http://hg.openjdk.java.net/jdk8/tl/langtools/rev/fa24eba012bd">http://hg.openjdk.java.net/jdk8/tl/langtools/rev/fa24eba012bd</a><br>
<br>
I believe that the removal of 'erasure' caused problems when eType
is a type-variable (as in this case).<br>
<br>
Maurizio<br>
<br>
On 03/04/13 09:58, Maurizio Cimadamore wrote:<br>
</div>
<blockquote cite="mid:515BEF21.9070505@oracle.com" type="cite">I
believe this is a regression, I will look into this
<br>
<br>
Maurizio
<br>
<br>
On 31/03/13 20:35, Werner Dietl wrote:
<br>
<blockquote type="cite">Take this simple example:
<br>
<br>
public class IterableTest {
<br>
interface Data extends Iterable<String> { }
<br>
<br>
void test(Iterable<? extends Data> t) {
<br>
for(Object a: t.iterator().next());
<br>
}
<br>
}
<br>
<br>
It compiles without errors using javac 1.6.0_27, 1.7.0_15, and
1.8.0 b82.
<br>
However, using the current jdk8/tl version results in:
<br>
<br>
IterableTest.java:5: error: iterator() in Iterable is defined in
an
<br>
inaccessible class or interface
<br>
for(Object a: t.iterator().next());
<br>
^
<br>
where T is a type-variable:
<br>
T extends Object declared in interface Iterable
<br>
1 error
<br>
<br>
Is this a desired error?
<br>
Can the error message be improved to highlight better what is
wrong?
<br>
<br>
Thanks for any help,
<br>
cu, WMD.
<br>
<br>
</blockquote>
<br>
</blockquote>
<br>
</body>
</html>