Skip to content

Commit

Permalink
Update src/Ideal.jl
Browse files Browse the repository at this point in the history
  • Loading branch information
fingolfin authored Aug 1, 2024
1 parent 18e5783 commit 9276a1b
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/Ideal.jl
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@
# for AbstractAlgebra rings.
# The functions in this file extend the interface for `ideal`.

# the following helper enables things like `ideal(R, [])` or `ideal(R, [1])`
# the type check ensures we don't run into an infinite recursion
function ideal(R::Ring, xs::AbstractVector{T}) where T<:RingElement
xs isa Vector{elem_type(R)} && error("ideals unsupported for ring $R")
return ideal(R, elem_type(R)[R(x) for x in xs])

Check warning on line 17 in src/Ideal.jl

View check run for this annotation

Codecov / codecov/patch

src/Ideal.jl#L15-L17

Added lines #L15 - L17 were not covered by tests
Expand Down

0 comments on commit 9276a1b

Please sign in to comment.