20 ms·
I wish they changed the spec so iterating over a null Iterable would not throw an NPE: Iterable items = null; for(Object x: items) { // will not enter th
by java-man 7y ago
I wish they changed the spec so iterating over a null Iterable would not throw an NPE:
Iterable items = null;
for(Object x: items)
{
// will not enter the loop
}