<html>
<head>
<base href="http://icedtea.classpath.org/bugzilla/" />
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW - [IcedTea6] Backport "7159445: (javac) emits inaccurate diagnostics for enhanced for-loops""
href="http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=3014">3014</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>[IcedTea6] Backport "7159445: (javac) emits inaccurate diagnostics for enhanced for-loops"
</td>
</tr>
<tr>
<th>Product</th>
<td>IcedTea
</td>
</tr>
<tr>
<th>Version</th>
<td>6-1.13.11
</td>
</tr>
<tr>
<th>Hardware</th>
<td>all
</td>
</tr>
<tr>
<th>OS</th>
<td>All
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>enhancement
</td>
</tr>
<tr>
<th>Priority</th>
<td>P5
</td>
</tr>
<tr>
<th>Component</th>
<td>IcedTea
</td>
</tr>
<tr>
<th>Assignee</th>
<td>gnu.andrew@redhat.com
</td>
</tr>
<tr>
<th>Reporter</th>
<td>gnu.andrew@redhat.com
</td>
</tr>
<tr>
<th>CC</th>
<td>unassigned@icedtea.classpath.org
</td>
</tr></table>
<p>
<div>
<pre>Error message in OpenJDK 8 / IcedTea 3.x is more helpful and specific.
$ /usr/lib/jvm/icedtea-6/bin/javac ForeachBadInitialization.java
ForeachBadInitialization.java:29: not a statement
for (a : s) {}
^
ForeachBadInitialization.java:29: ';' expected
for (a : s) {}
^
ForeachBadInitialization.java:29: illegal start of expression
for (a : s) {}
^
ForeachBadInitialization.java:29: ';' expected
for (a : s) {}
^
4 errors
$ /usr/lib/jvm/icedtea-8/bin/javac ForeachBadInitialization.java
ForeachBadInitialization.java:29: error: bad initializer for for-loop
for (a : s) {}
^
1 error</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are on the CC list for the bug.</li>
</ul>
</body>
</html>