[infinispan-dev] eclipse compiler bug prevents Infinispan core compilation

Sanne Grinovero sanne.grinovero at gmail.com
Tue Feb 9 14:50:11 EST 2010


Hi all,
the eclipse compiler is not as clever as Intellij's one; since this change
http://fisheye.jboss.org/browse/Infinispan/trunk/core/src/main/java/org/infinispan/util/Immutables.java?r1=1264&r2=1467

Infinispan core is not building any more in eclipse; could I revert
these changes, or change the <? extends T> types to <T> in method
signatures?

for example:
public static <T> Set<T> immutableSetCopy(Set<? extends T> set) {

could be changed to:
public static <T> Set<T> immutableSetCopy(Set<T> set) {

Alternatives:
1) change the signature
2) revert the change
3) introducing an explicit cast like:

return Collections.singleton(set.iterator().next());
to
return (Set<T>) Collections.singleton(set.iterator().next());

The commit log from Manik sais "IntelliJ Inspection refactoring", and
while he changed several classes I'm only having trouble with this one
class, in three methods.
Of course, this is not important as it doesn't affect the real build
and there is an issue open on the eclipse tracker;
I'm also switching slowly to intelliJ and building from commandline
maven, but could be annoying for others.

Sanne



More information about the infinispan-dev mailing list