Skip to content

Commit

Permalink
Merge pull request #188 from thofma/mpoly
Browse files Browse the repository at this point in the history
MPoly fixes
  • Loading branch information
wbhart committed Jun 6, 2017
2 parents 5d48980 + d2ef878 commit b108624
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/generic/MPoly.jl
Original file line number Diff line number Diff line change
Expand Up @@ -1861,7 +1861,7 @@ function divrem_monagan_pearce{T <: RingElem}(a::GenMPoly{T}, b::Array{GenMPoly{
n[i] == 0 && error("Division by zero in divrem_monagan_pearce")
end
if m == 0
return [par() for i in 1:len], [par() for i in 1:len]
return [par() for i in 1:len], par()
end
mask1 = UInt(1) << (bits - 1)
mask = UInt(0)
Expand Down Expand Up @@ -2607,7 +2607,7 @@ function (a::GenMPolyRing{T}){T <: RingElem}(b::PolyElem{T})
end

function (a::GenMPolyRing{T}){T <: RingElem}(b::Array{T, 1}, m::Array{UInt, 2})
if length(b) > 0
if length(b) > 0 && isdefined(b, 1)
parent(b[1]) != base_ring(a) && error("Unable to coerce to polynomial")
end
z = GenMPoly{T}(a, b, m)
Expand Down

0 comments on commit b108624

Please sign in to comment.