Skip to content

Commit

Permalink
add faster done for strings (JuliaLang#18259)
Browse files Browse the repository at this point in the history
  • Loading branch information
KristofferC authored Aug 29, 2016
1 parent d95fe92 commit 30ee10b
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions base/strings/string.jl
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,8 @@ end
return Char(c), i
end

done(s::String, state) = state > endof(s.data)

@inline function next(s::String, i::Int)
# function is split into this critical fast-path
# for pure ascii data, such as parsing numbers,
Expand Down

0 comments on commit 30ee10b

Please sign in to comment.