Use return without value instead of raising StopIteration