Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Type piracy in AbstractAlgebra #1387

Open
fingolfin opened this issue Jun 16, 2023 · 2 comments
Open

Type piracy in AbstractAlgebra #1387

fingolfin opened this issue Jun 16, 2023 · 2 comments

Comments

@fingolfin
Copy link
Member

fingolfin commented Jun 16, 2023

Enabling the type piracy report in test/Aqua.jl currently reports this (in Julia 1.10.3):

julia> using Aqua, AbstractAlgebra ; Aqua.test_piracies(AbstractAlgebra);
Possible type-piracy detected:
[1] gcd(a::T, b::T) where T<:AbstractFloat @ AbstractAlgebra ~/Projekte/OSCAR/AbstractAlgebra.jl/src/julia/Float.jl:107
[2] parent(a::T) where T<:AbstractFloat @ AbstractAlgebra ~/Projekte/OSCAR/AbstractAlgebra.jl/src/julia/Float.jl:17
[3] parent(a::T) where T<:Integer @ AbstractAlgebra ~/Projekte/OSCAR/AbstractAlgebra.jl/src/julia/Integer.jl:17
[4] parent(a::Rational{T}) where T<:Integer @ AbstractAlgebra ~/Projekte/OSCAR/AbstractAlgebra.jl/src/julia/Rational.jl:17
[5] sqrt(a::AbstractFloat; check) @ AbstractAlgebra ~/Projekte/OSCAR/AbstractAlgebra.jl/src/julia/Float.jl:135
[6] kwcall(::NamedTuple, ::typeof(sqrt), a::AbstractFloat) @ AbstractAlgebra ~/Projekte/OSCAR/AbstractAlgebra.jl/src/julia/Float.jl:135
@thofma
Copy link
Member

thofma commented Jun 16, 2023

Yes, these are base functions and base types. What do you suggest we do?

@fieker
Copy link
Contributor

fieker commented Jun 16, 2023

From Oscars point of view: we can remove them. From AA, there is nothing we can do...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants