Skip to content

Commit 9f6c163

Browse files
authored
adjust to new version of MutableArithmetics (#363)
1 parent 89878e1 commit 9f6c163

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ RecipesBase = "3cdcf5f2-1ef4-517c-9805-6587b60abb01"
1212

1313
[compat]
1414
Intervals = "0.5, 1.0, 1.3"
15-
MutableArithmetics = "0.2.15, 0.3"
15+
MutableArithmetics = "0.3"
1616
RecipesBase = "0.7, 0.8, 1"
1717
julia = "1"
1818

src/polynomials/mutable-arithmetics.jl

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ end
1414
"""
1515
add_conv(out::Vector{T}, E::Vector{T}, k::Vector{T})
1616
Returns the vector `out + fastconv(E, k)`. Note that only
17-
`MA.mutable_buffered_operate!` is implemented.
17+
`MA.buffered_operate!` is implemented.
1818
"""
1919
function add_conv end
2020

@@ -24,7 +24,7 @@ function add_conv end
2424
function MA.buffer_for(::typeof(add_conv), ::Type{Vector{T}}, ::Type{Vector{T}}, ::Type{Vector{T}}) where {T}
2525
return MA.buffer_for(MA.add_mul, T, T, T)
2626
end
27-
function MA.mutable_buffered_operate!(buffer, ::typeof(add_conv), out::Vector{T}, E::Vector{T}, k::Vector{T}) where {T}
27+
function MA.buffered_operate!(buffer, ::typeof(add_conv), out::Vector{T}, E::Vector{T}, k::Vector{T}) where {T}
2828
for x in eachindex(E)
2929
for i in eachindex(k)
3030
j = x + i - 1
@@ -56,11 +56,11 @@ macro register_mutable_arithmetic(name)
5656
return MA.buffer_for(add_conv, V, V, V)
5757
end
5858

59-
function MA.mutable_buffered_operate!(buffer, ::typeof(MA.add_mul),
59+
function MA.buffered_operate!(buffer, ::typeof(MA.add_mul),
6060
p::$poly, q::$poly, r::$poly)
6161
ps, qs, rs = coeffs(p), coeffs(q), coeffs(r)
6262
_resize_zeros!(ps, length(qs) + length(rs) - 1)
63-
MA.mutable_buffered_operate!(buffer, add_conv, ps, qs, rs)
63+
MA.buffered_operate!(buffer, add_conv, ps, qs, rs)
6464
return p
6565
end
6666
end

test/StandardBasis.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1476,8 +1476,8 @@ end
14761476
buffer = MA.buffer_for(MA.add_mul, typeof(c), typeof(A), typeof(b))
14771477
@test buffer isa BigInt
14781478
c = [z(2d - 1) for i in 1:m]
1479-
MA.mutable_buffered_operate!(buffer, MA.add_mul, c, A, b)
1479+
MA.buffered_operate!(buffer, MA.add_mul, c, A, b)
14801480
@test c == A * b
14811481
@test c == MA.operate(*, A, b)
1482-
@test 0 == @allocated MA.mutable_buffered_operate!(buffer, MA.add_mul, c, A, b)
1482+
@test 0 == @allocated MA.buffered_operate!(buffer, MA.add_mul, c, A, b)
14831483
end

0 commit comments

Comments
 (0)