Skip to content

Commit 3d0426e

Browse files
committed
Revert "Remove deprecations (and coming deprecations) (#190)"
This reverts commit 83374c1.
1 parent daa4923 commit 3d0426e

5 files changed

Lines changed: 14 additions & 14 deletions

File tree

src/array/ArrayBenchmarks.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -243,8 +243,8 @@ function perf_true_load!(result)
243243
return result
244244
end
245245

246-
n, vals = 10^6, -3:3
247-
a, b = samerand(vals, n), samerand(vals)
246+
n, range = 10^6, -3:3
247+
a, b = samerand(range, n), samerand(range)
248248

249249
boolarr = Vector{Bool}(undef, n)
250250
if VERSION >= v"0.7.0-DEV.2687"

src/array/subarray.jl

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,13 @@ function perf_lucompletepivCopy!(A)
1313
μ, λ = _maxind(As)
1414
μ += k-1; λ += k-1
1515
rowpiv[k] = μ
16-
A[[k,μ], 1:n] .= A[[μ,k], 1:n]
16+
A[[k,μ], 1:n] = A[[μ,k], 1:n]
1717
colpiv[k] = λ
18-
A[1:n, [k,λ]] .= A[1:n, [λ,k]]
18+
A[1:n, [k,λ]] = A[1:n, [λ,k]]
1919
if A[k,k] 0
2020
ρ = k+1:n
21-
A[ρ, k] ./= A[k, k]
22-
A[ρ, ρ] .-= A[ρ, k:k] .* A[k:k, ρ]
21+
A[ρ, k] = A[ρ, k]/A[k, k]
22+
A[ρ, ρ] = A[ρ, ρ] - A[ρ, k:k] * A[k:k, ρ]
2323
end
2424
end
2525
return (A, rowpiv, colpiv)
@@ -34,13 +34,13 @@ function perf_lucompletepivSub!(A)
3434
μ, λ = _maxind(As)
3535
μ += k-1; λ += k-1
3636
rowpiv[k] = μ
37-
A[[k,μ], 1:n] .= view(A, [μ,k], 1:n)
37+
A[[k,μ], 1:n] = view(A, [μ,k], 1:n)
3838
colpiv[k] = λ
39-
A[1:n, [k,λ]] .= view(A, 1:n, [λ,k])
39+
A[1:n, [k,λ]] = view(A, 1:n, [λ,k])
4040
if A[k,k] 0
4141
ρ = k+1:n
42-
A[ρ, k] ./= A[k, k]
43-
A[ρ, ρ] .-= view(A, ρ, k:k) .* view(A, k:k, ρ)
42+
A[ρ, k] = view(A, ρ, k)/A[k, k]
43+
A[ρ, ρ] = view(A, ρ, ρ) - view(A, ρ, k:k) * view(A, k:k, ρ)
4444
end
4545
end
4646
return (A, rowpiv, colpiv)

src/array/sumindex.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -287,7 +287,7 @@ end
287287
function makearrays(::Type{T}, r::Integer, c::Integer) where T
288288
A = samerand(T, r, c)
289289
B = similar(A, r+1, c+1)
290-
B[1:r, 1:c] .= A
290+
B[1:r, 1:c] = A
291291
AS = ArrayLS(B)
292292
ASS = ArrayLSLS(B)
293293
AF = ArrayLF(A)

src/problem/GoGame.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -351,15 +351,15 @@ function generate_move(board::Board, color::Int)
351351
# Further require the move not to be suicide for the opponent...
352352
if !suicide(board, ai, aj, other_color(color))
353353
num_moves += 1
354-
moves[:,num_moves] .= (ai, aj)
354+
moves[:,num_moves] = [ai, aj]
355355
else
356356
# ...however, if the move captures at least one stone,
357357
# consider it anyway.
358358
for k = 1:4
359359
(bi, bj) = neighbor(ai, aj, k)
360360
if on_board(board, bi, bj) && board[bi, bj] == other_color(color)
361361
num_moves += 1
362-
moves[:,num_moves] .= (ai, aj)
362+
moves[:,num_moves] = [ai, aj]
363363
break
364364
end
365365
end

src/problem/Laplacian.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ function ddx_spdiags(m)
3333
# Append new d[k]-th diagonal to compact form
3434
for k = 1:p
3535
i = max(1,1-d[k]):min(m,n-d[k])
36-
a[(len[k]+1):len[k+1],:] .= [i i.+d[k] B[i.+(m>=n)*d[k],k]]
36+
a[(len[k]+1):len[k+1],:] = [i i.+d[k] B[i.+(m>=n)*d[k],k]]
3737
end
3838

3939
return sparse(a[:,1], a[:,2], a[:,3], m, n)

0 commit comments

Comments
 (0)