Skip to content

Commit 723e025

Browse files
authored
coefficienttype -> coefficient_type (#129)
* coefficienttype -> coefficient_type * Remove incorrect method
1 parent e05f419 commit 723e025

File tree

5 files changed

+6
-7
lines changed

5 files changed

+6
-7
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,6 @@ jobs:
5252
with:
5353
depwarn: error
5454
- uses: julia-actions/julia-processcoverage@v1
55-
- uses: codecov/codecov-action@v1
55+
- uses: codecov/codecov-action@v3
5656
with:
5757
file: lcov.info

src/DynamicPolynomials.jl

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,6 @@ MP.term_type(::Union{PolyType{C}, Type{<:PolyType{C}}}, ::Type{T}) where {C, T}
3535
MP.term_type(::Type{Polynomial{C}}) where {C} = Term{C}
3636
MP.polynomial_type(::Type{Term{C}}) where {C} = Polynomial{C}
3737
MP.polynomial_type(::Type{Term{C, T}}) where {T, C} = Polynomial{C, T}
38-
MP.polynomial_type(::Type{T}, ::Type{<:DMonomialLike{C}}) where {T, C} = Polynomial{C, T}
3938
MP.polynomial_type(::Union{PolyType{C}, Type{<:PolyType{C}}}, ::Type{T}) where {C, T} = Polynomial{C, T}
4039
_vars(p::AbstractArray{<:PolyType}) = mergevars(_vars.(p))[1]
4140
MP.variables(p::Union{PolyType, MonomialVector, AbstractArray{<:PolyType}}) = _vars(p) # tuple(_vars(p))

src/mult.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ function Base.:(*)(p::Polynomial{true, S}, q::Polynomial{true, T}) where {S, T}
105105
if iszero(p) || iszero(q)
106106
zero(PT)
107107
else
108-
polynomialclean(_mul(MP.coefficienttype(PT), p, q)...)
108+
polynomialclean(_mul(MP.coefficient_type(PT), p, q)...)
109109
end
110110
end
111111
function MA.operate_to!(p::Polynomial{false, T}, ::typeof(*), q1::MP.AbstractPolynomialLike, q2::MP.AbstractPolynomialLike) where T

src/subs.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ function _subs(::MP.Eval, p::Polynomial{C, T}, vals::AbstractVector{S}) where {C
9393
end
9494
end
9595
function _subs(::MP.Subs, p::Polynomial{C, T}, vals::AbstractVector{S}) where {C, T, S}
96-
Tout = MA.promote_operation(*, T, MP.coefficienttype(S))
96+
Tout = MA.promote_operation(*, T, MP.coefficient_type(S))
9797
q = zero_with_variables(Polynomial{C, Tout}, mergevars_of(PolyVar{C}, vals)[1])
9898
for i in 1:length(p.a)
9999
MA.operate!(+, q, p.a[i] * monoeval(p.x.Z[i], vals))

test/poly.jl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
@testset "Term and Polynomial tests" begin
22
@testset "Term" begin
33
@polyvar x
4-
# @test coefficienttype(1x) == Int
5-
# @test coefficienttype(1.0x^2) == Float64
6-
# @test coefficienttype(Term{true, Int}) == Int
4+
# @test coefficient_type(1x) == Int
5+
# @test coefficient_type(1.0x^2) == Float64
6+
# @test coefficient_type(Term{true, Int}) == Int
77
@test zero_term(Term{false, Int}).α == 0
88
@test one(Term{true, Int}).α == 1
99
@polyvar x

0 commit comments

Comments
 (0)