diff --git a/Project.toml b/Project.toml index 20c3e68ff..9996845be 100644 --- a/Project.toml +++ b/Project.toml @@ -1,6 +1,6 @@ name = "Nemo" uuid = "2edaba10-b0f1-5616-af89-8c11ac63239a" -version = "0.37.0" +version = "0.37.1" [deps] AbstractAlgebra = "c3fe647b-3220-5bb0-a1ea-a7954cac585d" diff --git a/docs/src/ff_embedding.md b/docs/src/ff_embedding.md index 2941cfe41..56ff99fdf 100644 --- a/docs/src/ff_embedding.md +++ b/docs/src/ff_embedding.md @@ -41,9 +41,9 @@ julia> k4, x4 = finite_field(19, 4, "x4") (Finite field of degree 4 over GF(19), x4) julia> f = embed(k2, k4) -Morphism of finite fields from - from finite field of degree 2 over gF(19) - to finite field of degree 4 over gF(19) +Morphism of finite fields + from finite field of degree 2 over GF(19) + to finite field of degree 4 over GF(19) julia> y = f(x2) 6*x4^3 + 5*x4^2 + 9*x4 + 17 @@ -69,7 +69,9 @@ julia> k21, x21 = finite_field(13, 21, "x21") (Finite field of degree 21 over GF(13), x21) julia> s = preimage_map(k7, k21) -Preimage of the morphism from Finite field of degree 7 over GF(13) to Finite field of degree 21 over GF(13) +Preimage of a morphism + from finite field of degree 7 over GF(13) + to finite field of degree 21 over GF(13) julia> y = k21(x7); diff --git a/src/embedding/EmbeddingTypes.jl b/src/embedding/EmbeddingTypes.jl index 21745440e..dbbbe0a11 100644 --- a/src/embedding/EmbeddingTypes.jl +++ b/src/embedding/EmbeddingTypes.jl @@ -27,15 +27,6 @@ function (f::FinFieldMorphism)(x) return image_fn(f)(x)::elem_type(codomain(f)) end -function show(io::IO, ::MIME"text/plain", f::FinFieldMorphism) - println(io, "Morphism of finite fields from") - io = pretty(io) - print(io, Indent(), "from ", Lowercase(), domain(f)) - println(io) - print(io, "to ", Lowercase(), codomain(f)) - print(io, Dedent()) -end - function show(io::IO, f::FinFieldMorphism) if get(io, :supercompact, false) print(io, "Morphism of finite fields") @@ -76,7 +67,12 @@ function (f::FinFieldPreimage)(x) end function Base.show(io::IO, f::FinFieldPreimage) - print(io, "Preimage of the morphism from $(domain(f)) to $(codomain(f))") + if get(io, :supercompact, false) + print(io, "Preimage of a morphism") + else + print(io, "Hom: ") + print(IOContext(io, :supercompact => true), domain(f), " -> ", codomain(f)) + end end @doc raw"""