Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

make replace with count=0 a no-op #22325

Merged
merged 13 commits into from
Jul 4, 2017
Merged
Prev Previous commit
Next Next commit
remove un-needed Base. prefix
  • Loading branch information
rfourquet committed Jul 4, 2017
commit d77b51a5895a20f303b33b06f75139917eb89881
2 changes: 1 addition & 1 deletion base/deprecated.jl
Original file line number Diff line number Diff line change
Expand Up @@ -1510,7 +1510,7 @@ function replace(s::AbstractString, pat, f, n::Integer)
depwarn(string("`replace(s, pat, r, count)` with `count <= 0` is deprecated, use ",
"`replace(s, pat, r, typemax(Int))` or replace(s, pat, r)` instead"),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing opening backtick.

:replace)
Base.replace(s, pat, f)
replace(s, pat, f)
else
Base.replace_new(String(s), pat, f, clamp(n, 0, typemax(Int)) % Int)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Base. shouldn't be needed here either, deprecated.jl is included within the Base module

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sorry I should have checked

end
Expand Down