1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-08-03 14:25:37 +02:00

Fixes warnings

This commit is contained in:
Markus Schorn 2008-03-27 14:31:34 +00:00
parent 5001cf3e33
commit c10395201b
2 changed files with 6 additions and 5 deletions

View file

@ -19,6 +19,11 @@ public final class EmptyIterator<T> implements Iterator<T>
public static final EmptyIterator<?> EMPTY_ITERATOR = new EmptyIterator<Object>();
@SuppressWarnings("unchecked")
public static <T> EmptyIterator<T> empty() {
return (EmptyIterator<T>) EMPTY_ITERATOR;
}
private EmptyIterator()
{
}

View file

@ -76,12 +76,8 @@ public class PartialWorkingCopyCodeReaderFactory
return cache.get( path );
}
/**
* @return
*/
@SuppressWarnings("unchecked")
protected Iterator<IWorkingCopy> createWorkingCopyIterator() {
if( provider == null ) return EmptyIterator.EMPTY_ITERATOR;
if( provider == null ) return EmptyIterator.empty();
return Arrays.asList( provider.getWorkingCopies() ).iterator();
}