Skip to content

Commit

Permalink
Make more parent types attribute storing (#1668)
Browse files Browse the repository at this point in the history
For now I excluded modules and ideals from this.
  • Loading branch information
fingolfin authored Apr 16, 2024
1 parent 96b9d54 commit bac739e
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 11 deletions.
20 changes: 10 additions & 10 deletions src/generic/GenericTypes.jl
Original file line number Diff line number Diff line change
Expand Up @@ -495,7 +495,7 @@ end

abstract type LaurentPolyRing{T} <: AbstractAlgebra.LaurentPolyRing{T} end

mutable struct LaurentPolyWrapRing{T <: RingElement,
@attributes mutable struct LaurentPolyWrapRing{T <: RingElement,
PR <: AbstractAlgebra.PolyRing{T}
} <: LaurentPolyRing{T}
polyring::PR
Expand Down Expand Up @@ -612,7 +612,7 @@ end
#
###############################################################################

mutable struct EuclideanRingResidueField{T <: RingElement} <: AbstractAlgebra.ResidueField{T}
@attributes mutable struct EuclideanRingResidueField{T <: RingElement} <: AbstractAlgebra.ResidueField{T}
base_ring::Ring
modulus::T

Expand Down Expand Up @@ -755,7 +755,7 @@ end
#
###############################################################################

mutable struct LaurentSeriesField{T <: FieldElement} <: AbstractAlgebra.Field
@attributes mutable struct LaurentSeriesField{T <: FieldElement} <: AbstractAlgebra.Field
base_ring::Field
prec_max::Int
S::Symbol
Expand Down Expand Up @@ -816,7 +816,7 @@ end
#
###############################################################################

mutable struct PuiseuxSeriesField{T <: FieldElement} <: AbstractAlgebra.Field
@attributes mutable struct PuiseuxSeriesField{T <: FieldElement} <: AbstractAlgebra.Field
laurent_ring::Field

function PuiseuxSeriesField{T}(R::LaurentSeriesField{T}, cached::Bool = true) where T <: FieldElement
Expand Down Expand Up @@ -846,7 +846,7 @@ const PuiseuxSeriesElem{T} = Union{PuiseuxSeriesRingElem{T}, PuiseuxSeriesFieldE
#
###############################################################################

mutable struct AbsMSeriesRing{T <: RingElement, S} <:
@attributes mutable struct AbsMSeriesRing{T <: RingElement, S} <:
AbstractAlgebra.MSeriesRing{T}
poly_ring::AbstractAlgebra.MPolyRing{T}
prec_max::Vector{Int} # used for weights in weighted mode
Expand Down Expand Up @@ -894,7 +894,7 @@ end
#
###############################################################################

mutable struct FracField{T <: RingElem} <: AbstractAlgebra.FracField{T}
@attributes mutable struct FracField{T <: RingElem} <: AbstractAlgebra.FracField{T}
base_ring::Ring

function FracField{T}(R::Ring, cached::Bool = true) where T <: RingElem
Expand Down Expand Up @@ -946,7 +946,7 @@ end
#
###############################################################################

mutable struct FactoredFracField{T <: RingElement} <: AbstractAlgebra.FracField{T}
@attributes mutable struct FactoredFracField{T <: RingElement} <: AbstractAlgebra.FracField{T}
base_ring::AbstractAlgebra.Ring

function FactoredFracField{T}(R::Ring, cached::Bool = true) where T <: RingElement
Expand Down Expand Up @@ -979,7 +979,7 @@ end
#
###############################################################################

mutable struct RationalFunctionField{T <: FieldElement, U <: Union{PolyRingElem{T}, MPolyRingElem{T}}} <: AbstractAlgebra.Field
@attributes mutable struct RationalFunctionField{T <: FieldElement, U <: Union{PolyRingElem{T}, MPolyRingElem{T}}} <: AbstractAlgebra.Field
S::Union{Symbol, Vector{Symbol}}
fraction_field::FracField{U}
base_ring::Field
Expand Down Expand Up @@ -1007,7 +1007,7 @@ end
#
###############################################################################

mutable struct FunctionField{T <: FieldElement} <: AbstractAlgebra.Field
@attributes mutable struct FunctionField{T <: FieldElement} <: AbstractAlgebra.Field
num::Poly{<:PolyRingElem{T}}
den::PolyRingElem{T}
S::Symbol
Expand Down Expand Up @@ -1141,7 +1141,7 @@ end
#
###############################################################################

mutable struct FreeAssAlgebra{T <: RingElement} <: AbstractAlgebra.FreeAssAlgebra{T}
@attributes mutable struct FreeAssAlgebra{T <: RingElement} <: AbstractAlgebra.FreeAssAlgebra{T}
base_ring::Ring
S::Vector{Symbol}

Expand Down
2 changes: 1 addition & 1 deletion src/julia/JuliaTypes.jl
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ end
#
###############################################################################

mutable struct GFField{T <: Integer} <: FinField
@attributes mutable struct GFField{T <: Integer} <: FinField
p::T

function GFField{T}(p::T; cached::Bool = true) where T <: Integer
Expand Down

0 comments on commit bac739e

Please sign in to comment.