JuliaLang/Iterators.jl — pull request #11 by kmsquire (2013-11-12 08:07:47+00:00)
Title: Added eltype, length for most iterators

* Useful for type inference, collect() usage

Before:
```julia
julia> collect(take(count(1.0, pi), 5))
5-element Array{Any,1}:
1.0
4.14159
7.28319
10.4248
13.5664

julia> @time collect(take(count(1.0, pi), 1000000));
elapsed time: 0.575649318 seconds (128770240 bytes allocated)
```

After:
```julia
julia> collect(take(count(1.0, pi), 5))
5-element Array{Float64,1}:
1.0
4.14159
7.28319
10.4248
13.5664

julia> @time collect(take(count(1.0, pi), 1000000));
elapsed time: 0.331517091 seconds (103992064 bytes allocated)
```