Skip to content

Commit 3b8a5f7

Browse files
committed
cumsum_kbn using where syntax
1 parent 3914e8d commit 3b8a5f7

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

base/abstractarraymath.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -210,7 +210,7 @@ function circshift(a::AbstractArray, shiftamt)
210210
end
211211

212212
# Uses K-B-N summation
213-
function cumsum_kbn{T<:AbstractFloat}(v::AbstractVector{T})
213+
function cumsum_kbn(v::AbstractVector{T}) where T<:AbstractFloat
214214
r = similar(v)
215215
if isempty(v); return r; end
216216

@@ -241,7 +241,7 @@ end
241241
Cumulative sum along a dimension, using the Kahan-Babuska-Neumaier compensated summation
242242
algorithm for additional accuracy. The dimension defaults to 1.
243243
"""
244-
function cumsum_kbn{T<:AbstractFloat}(A::AbstractArray{T}, axis::Integer=1)
244+
function cumsum_kbn(A::AbstractArray{T}, axis::Integer=1) where T<:AbstractFloat
245245
dimsA = size(A)
246246
ndimsA = ndims(A)
247247
axis_size = dimsA[axis]

0 commit comments

Comments
 (0)