Skip to content

Commit

Permalink
Fix type instability in number_moved_points (#670)
Browse files Browse the repository at this point in the history
  • Loading branch information
thofma authored and fieker committed Sep 30, 2021
1 parent 00f6abd commit 726222f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Groups/GAPGroups.jl
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ julia> length(moved_points(gen(s, 1)))
```
""" moved_points

@gapattribute number_moved_points(x::Union{PermGroupElem,PermGroup}) = fmpz(GAP.Globals.NrMovedPoints(x.X))
@gapattribute number_moved_points(x::Union{PermGroupElem,PermGroup}) = fmpz(GAP.Globals.NrMovedPoints(x.X))::fmpz
"""
number_moved_points(::Type{T} = fmpz, x::PermGroupElem) where T <: Union{Integer, fmpz}
number_moved_points(::Type{T} = fmpz, G::PermGroup) where T <: Union{Integer, fmpz}
Expand All @@ -214,7 +214,7 @@ julia> number_moved_points(gen(s, 1))
```
""" number_moved_points

number_moved_points(::Type{T}, x::Union{PermGroupElem,PermGroup}) where T <: Union{Base.Integer, fmpz} = T(GAP.Globals.NrMovedPoints(x.X))
number_moved_points(::Type{T}, x::Union{PermGroupElem,PermGroup}) where T <: Union{Base.Integer, fmpz} = T(GAP.Globals.NrMovedPoints(x.X))::T


"""
Expand Down

0 comments on commit 726222f

Please sign in to comment.