diff --git a/base/multidimensional.jl b/base/multidimensional.jl index d5c03ec95d135..49d09ea449e5c 100644 --- a/base/multidimensional.jl +++ b/base/multidimensional.jl @@ -932,7 +932,10 @@ See also [`circshift`](@ref). axes(dest) == inds || throw(ArgumentError("indices of src and dest must match (got $inds and $(axes(dest)))")) _circshift!(dest, (), src, (), inds, fill_to_length(shiftamt, 0, Val(N))) end -circshift!(dest::AbstractArray, src, shiftamt) = circshift!(dest, src, (shiftamt...,)) + +_circshift_helper!(dest::AbstractArray, src, shiftamt) = circshift!(dest, src, (shiftamt...,)) +_circshift_helper!(dest::AbstractArray, src, shiftamt::Integer) = circshift!(dest, src, (shiftamt,)) +circshift!(dest::AbstractArray, src, shiftamt) = _circshift_helper!(dest, src, shiftamt) # For each dimension, we copy the first half of src to the second half # of dest, and the second half of src to the first half of dest. This