Skip to content

Commit

Permalink
fix [map]reduce deprecations, take 3 (#27884)
Browse files Browse the repository at this point in the history
  • Loading branch information
fredrikekre authored Jul 1, 2018
1 parent d917f65 commit 656d587
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions base/deprecated.jl
Original file line number Diff line number Diff line change
Expand Up @@ -1716,7 +1716,7 @@ end
@deprecate_moved svds "Arpack"

# PR #27711
function reduce(op, v0, itr::AbstractArray; dims=nothing)
function reduce(op, v0, itr; dims=nothing)
if dims === nothing
depwarn("`reduce(op, v0, itr)` is deprecated, use `reduce(op, itr; init=v0)` instead", :reduce)
return reduce(op, itr, init=v0)
Expand All @@ -1727,7 +1727,7 @@ function reduce(op, v0, itr::AbstractArray; dims=nothing)
end
@deprecate foldl(op, v0, itr) foldl(op, itr; init=v0)
@deprecate foldr(op, v0, itr) foldr(op, itr; init=v0)
function mapreduce(f, op, v0, itr::AbstractArray; dims=nothing)
function mapreduce(f, op, v0, itr; dims=nothing)
if dims === nothing
depwarn("`mapreduce(f, op, v0, itr)` is deprecated, use `mapreduce(f, op, itr; init=v0)` instead", :mapreduce)
return mapreduce(f, op, itr; init=v0)
Expand Down

0 comments on commit 656d587

Please sign in to comment.